diff options
author | Rob Mohr <mohrr@google.com> | 2020-08-04 15:19:49 -0700 |
---|---|---|
committer | CQ Bot Account <commit-bot@chromium.org> | 2020-08-05 15:00:51 +0000 |
commit | 4ba68e2ab5a7bdf9b55409365c069e42e631b530 (patch) | |
tree | 11c6c3189f5a4ab087c2e51aaac36cd7f327f3c0 /docker | |
parent | 47008e815bb0a09de7a254dfb2f43cc41dd8d283 (diff) | |
download | pigweed-4ba68e2ab5a7bdf9b55409365c069e42e631b530.tar.gz |
docker: Add details to docs
Bug: 216
Change-Id: If4134c77e40ecfe9d9407e008c53a0c2c3266729
Reviewed-on: https://pigweed-review.googlesource.com/c/pigweed/pigweed/+/15400
Reviewed-by: Keir Mierle <keir@google.com>
Commit-Queue: Rob Mohr <mohrr@google.com>
Diffstat (limited to 'docker')
-rw-r--r-- | docker/docs.rst | 25 |
1 files changed, 20 insertions, 5 deletions
diff --git a/docker/docs.rst b/docker/docs.rst index 3c25edc73..a5e26c0ba 100644 --- a/docker/docs.rst +++ b/docker/docs.rst @@ -3,10 +3,25 @@ ------ docker ------ -The Dockerfile in this directory simplifies creating a container with cached -CIPD packages for use in continuous integration. +``pw_env_setup`` reliably initializes a working environment for Pigweed, but +can take awhile to run. It intelligently caches where it can, but that caching +is designed around a particular execution environment. That environment +assumption is poor when running tests with docker. To help out teams using +docker for automated testing, the Pigweed team has a publicly-available docker +image with a cache of some of the Pigweed environment. The current tag of this +image is in ``docker/tag`` under the Pigweed checkout. -To create a container run ``docker build --tag <tag> $PW_ROOT/docker``. To run -this image run ``docker run -it <tag>``. +To build your own docker image, start with ``docker/Dockerfile.cache`` and +run ``docker build --file docker/Dockerfile.cache .`` from the root of your +Pigweed checkout. -Details of Docker use are unfinished. +To use the publicly-available docker image, run +``docker build --file docker/Dockerfile.run --build-arg from=$(cat docker/tag) .`` +from the root of your Pigweed checkout. You still need to run +``. ./bootstrap.sh`` within the docker image, but it should complete much +faster than on a vanilla docker image. + +We're still trying to improve this process, so if you have any ideas for +improvements please `send us a note`_. + +.. _send us a note: pigweed@googlegroups.com |