mirror of
https://github.com/docker/docs.git
synced 2026-04-05 02:38:52 +07:00
Merge pull request #11844 from jbarbier/cgroup-parent-42
Adding cgroup-parent option for docker build
This commit is contained in:
@@ -642,8 +642,9 @@ is returned by the `docker attach` command to its caller too:
|
||||
-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 execution, e.g. `0-3`, `0,1`
|
||||
--cpuset-mems="" MEMs in which to allow execution, e.g. `0-3`, `0,1`
|
||||
--cpuset-cpus="" CPUs in which to allow exection, e.g. `0-3`, `0,1`
|
||||
--cgroup-parent="" Optional parent cgroup for the container
|
||||
|
||||
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
|
||||
@@ -862,6 +863,11 @@ you refer to it on the command line.
|
||||
> children) for security reasons, and to ensure repeatable builds on remote
|
||||
> Docker hosts. This is also the reason why `ADD ../file` will not work.
|
||||
|
||||
When `docker build` is run with the `--cgroup-parent` option the containers used
|
||||
in the build will be run with the [corresponding `docker run`
|
||||
flag](/reference/run/#specifying-custom-cgroups).
|
||||
|
||||
|
||||
## commit
|
||||
|
||||
Usage: docker commit [OPTIONS] CONTAINER [REPOSITORY[:TAG]]
|
||||
|
||||
@@ -465,6 +465,13 @@ Note:
|
||||
|
||||
You would have to write policy defining a `svirt_apache_t` type.
|
||||
|
||||
## Specifying custom cgroups
|
||||
|
||||
Using the `--cgroup-parent` flag, you can pass a specific cgroup to run a
|
||||
container in. This allows you to create and manage cgroups on their own. You can
|
||||
define custom resources for those cgroups and put containers under a common
|
||||
parent group.
|
||||
|
||||
## Runtime constraints on resources
|
||||
|
||||
The operator can also adjust the performance parameters of the
|
||||
|
||||
Reference in New Issue
Block a user