Allow setting resource constrains for build

Closes #10191

Allow `docker build` to set --cpu-shares, --cpuset, --memory,
--memory-swap for all containers created by the build.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
master
Brian Goff 2015-02-06 09:33:01 -05:00 committed by Tibor Vass
parent 4aa65f26aa
commit edc7c88640
1 changed files with 4 additions and 0 deletions

View File

@ -515,6 +515,10 @@ is returned by the `docker attach` command to its caller too:
-q, --quiet=false Suppress the verbose output generated by the containers
--rm=true Remove intermediate containers after a successful build
-t, --tag="" Repository name (and optionally a tag) for the image
-m, --memory="" Memory limit for all build containers
--memory-swap="" Total memory (memory + swap), `-1` to disable swap
-c, --cpu-shares CPU Shares (relative weight)
--cpuset-cpus="" CPUs in which to allow exection, e.g. `0-3`, `0,1`
Builds Docker images from a Dockerfile and a "context". A build's context is
the files located in the specified `PATH` or `URL`. The build process can