0
Fork 0
mirror of https://github.com/Droid-VM/crosvm.git synced 2026-11-17 06:58:03 +00:00
crosvm/tools/impl/dev_container
Daniel Verkamp b952f534a0 dev_container: pull crosvm_dev_base when building crosvm_dev
When building the crosvm_dev container on a system that did not build
crosvm_dev_base, it is necessary to pull the published image first.

BUG=b:395695390,b:382504192
TEST=make -C tools/impl/dev_container crosvm_dev

Change-Id: I7b5f49b325adf1ac80082596df851bd4b302c366
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/6257030
Reviewed-by: Dennis Kempin <denniskempin@google.com>
Commit-Queue: Daniel Verkamp <dverkamp@chromium.org>
History 2025-02-12 11:02:44 -08:00
..
base_version tools: Separate debian packages from other setup 2025-02-11 15:10:36 -08:00
Dockerfile tools: Separate debian packages from other setup 2025-02-11 15:10:36 -08:00
Dockerfile.base tools: Separate debian packages from other setup 2025-02-11 15:10:36 -08:00
Makefile dev_container: pull crosvm_dev_base when building crosvm_dev 2025-02-12 11:02:44 -08:00
README.md tools: Separate debian packages from other setup 2025-02-11 15:10:36 -08:00
version tools: Separate debian packages from other setup 2025-02-11 15:10:36 -08:00

Dev Container

This directory contains the dev container used by developers locally as well as the crosvm CI infrastructure.

The container is split into two, crosvm_dev defined by tools/impl/dev_container/Dockerfile and crosvm_dev_base defined by tools/impl/dev_container/Dockerfile.base.

crosvm_dev_base

The Dockerfile.base image contains a plain debian image with only debian packages from tools/deps/install-*-debs installed. Since we track debian testing, new packages can come with new problems and that image should not be updated very often.

To make changes to those debian packages, modify the install scripts and uprev the tools/impl/dev_container/base_version file. Then rebuild the container with:

make -C tools/impl/dev_container crosvm_dev_base

Then proceed below to rebuild the crosvm_dev container using the new base image as well and upload both.

crosvm_dev

The Dockerfile builds the dev container on top of crosvm_dev_base, so we are free to uprev tooling without having to pull in new debian packages.

To make changes to crosvm_dev, modify the corresponding install scripts and uprev the tools/impl/dev_container/version file. Then rebuild the container with:

make -C tools/impl/dev_container crosvm_dev

This will make the image available for testing locally with tools/dev_container. You may have to stop the previous container to pick up the new image tools/dev_container --stop.

To upload the new version of the containers run:

make -C tools/impl/dev_container upload

You need to be a Googler to be able to do so. See go/crosvm/infra for access control and authenticate via:

gcloud auth configure-docker gcr.io