Service Configuration Options Guide
build - Configuration options that are applied at build time
-
context - Either a path to a directory containing a Dockerfile, or a url to a git repository
-
dockerfile - Alternate Dockerfile
-
args - Add build arguments, which are environment variables accessible only during the build process
-
cache_from - A list of images that the engine uses for cache resolution
-
labels - Add metadata to the resulting image using Docker labels. You can use either an array or a dictionary.
-
shm_size - Set the size of the/dev/shmpartition for this build's containers. Specify as an integer value representing the number of bytes or as a string expressing a byte value.
-
target - Build the specified stage as defined inside theDockerfile
cap_add, cap_drop
Add or drop container capabilities
command
Override the default command.
configs
Grant access to configs on a per-service basis using the per-serviceconfigsconfiguration.
cgroup_parent
Specify an optional parent cgroup for the container.
container_name
Specify a custom container name, rather than a generated default name.