DockerBuildOptions
Docker build options.
Initializer
import ros_cdk_core
ros_cdk_core.DockerBuildOptions(
build_args: typing.Mapping[str] = None,
cache_disabled: bool = None,
cache_from: typing.List[DockerCacheOption] = None,
cache_to: DockerCacheOption = None,
file: str = None,
platform: str = None,
target_stage: str = None
)
Properties
Name | Type | Description |
---|---|---|
build_args |
typing.Mapping[str] |
Build args. |
cache_disabled |
bool |
Disable the cache and pass --no-cache to the docker build command. |
cache_from |
typing.List[DockerCacheOption] |
Cache from options to pass to the docker build command. |
cache_to |
DockerCacheOption |
Cache to options to pass to the docker build command. |
file |
str |
Name of the Dockerfile, must relative to the docker build path. |
platform |
str |
Set platform if server is multi-platform capable. Requires Docker Engine API v1.38+. |
target_stage |
str |
Set build target for multi-stage container builds. Any stage defined afterwards will be ignored. |
build_args
Optional
build_args: typing.Mapping[str]
- Type: typing.Mapping[str]
- Default: no build args
Build args.
cache_disabled
Optional
cache_disabled: bool
- Type: bool
- Default: cache is used
Disable the cache and pass --no-cache
to the docker build
command.
cache_from
Optional
cache_from: typing.List[DockerCacheOption]
- Type: typing.List[DockerCacheOption]
- Default: no cache from args are passed
Cache from options to pass to the docker build
command.
cache_to
Optional
cache_to: DockerCacheOption
- Type: DockerCacheOption
- Default: no cache to args are passed
Cache to options to pass to the docker build
command.
file
Optional
file: str
- Type: str
- Default:
Dockerfile
Name of the Dockerfile, must relative to the docker build path.
platform
Optional
platform: str
- Type: str
- Default: no platform specified
Set platform if server is multi-platform capable. Requires Docker Engine API v1.38+.
Example value: linux/amd64
target_stage
Optional
target_stage: str
- Type: str
- Default: Build all stages defined in the Dockerfile
Set build target for multi-stage container builds. Any stage defined afterwards will be ignored.
Example value: build-env