From e0489abec1de622140b12e32373cb2258e8bbc1e Mon Sep 17 00:00:00 2001 From: Andreea Florescu Date: Thu, 23 Mar 2023 14:27:57 +0100 Subject: [PATCH] add runbook for updating the Rust version in CI Signed-off-by: Andreea Florescu --- docs/readme.md | 3 ++- docs/update-rust-toolchain.md | 29 +++++++++++++++++++++++++++++ 2 files changed, 31 insertions(+), 1 deletion(-) create mode 100644 docs/update-rust-toolchain.md diff --git a/docs/readme.md b/docs/readme.md index 1edaa73..946850e 100644 --- a/docs/readme.md +++ b/docs/readme.md @@ -6,4 +6,5 @@ of development in the rust-vmm project. ## Table of Contents - [Code Coverage](code_coverage.md) - [Crate Release](crate_release.md) -- [Set Up a New Repository](setup_new_repo.md) \ No newline at end of file +- [Set Up a New Repository](setup_new_repo.md) +- [Update the Rust Toolchain](update-rust-toolchain.md) \ No newline at end of file diff --git a/docs/update-rust-toolchain.md b/docs/update-rust-toolchain.md new file mode 100644 index 0000000..e5ec90f --- /dev/null +++ b/docs/update-rust-toolchain.md @@ -0,0 +1,29 @@ +# Update Rust Toolchain + +The Rust version used for running the tests in rust-vmm crates is fixed such +that toolchain updates can only happen when the version is explicitly updated. + +The Rust version is specified in the +[rust-vmm-container](https://github.com/rust-vmm/rust-vmm-container), and the +rust-vmm-container version is specified in +[rust-vmm-ci](https://github.com/rust-vmm/rust-vmm-ci). While rust-vmm-ci +does not declare a version itself, in the rust-vmm crates we are specifying +which commit from rust-vmm-ci to use for running the CI. + +Thus, to update the Rust toolchain (or for that matter any other tools in the +CI), you need to go through the following updates: + +1. Update the Rust toolchain version in the rust-vmm-container +[Dockerfile](https://github.com/rust-vmm/rust-vmm-container/blob/main/Dockerfile). +Open a PR with your change. Once the PR is approved and merged, the merge +will automatically trigger the publishing of a new container version. For more +details about how this works, you can check the rust-vmm-container +[README](https://github.com/rust-vmm/rust-vmm-container). +2. Update the rust-vmm-container version in the rust-vmm-ci +[autogenerate script](https://github.com/rust-vmm/rust-vmm-ci/blob/c2f8c93e3796d8b3ea7dc339fad211457be9c238/.buildkite/autogenerate_pipeline.py#L63). +and open a PR with your change. Once this is merged, you can go ahead with +updating the rust-vmm-ci submodule. +3. Update the rust-vmm-ci for the target rust-vmm repository. NOTE: the +rust-vmm-ci submodule is automatically updated using Dependabot +every week. If for any reason you need this update faster than the default +schedule, you can follow the runbook for manually updating rust-vmm-ci.