pub struct DockerBuildStrategy {
pub build_args: Option<Vec<EnvVar>>,
pub dockerfile_path: Option<String>,
pub env: Option<Vec<EnvVar>>,
pub force_pull: Option<bool>,
pub from: Option<ObjectReference>,
pub image_optimization_policy: Option<String>,
pub no_cache: Option<bool>,
pub pull_secret: Option<LocalObjectReference>,
}
Expand description
DockerBuildStrategy defines input parameters specific to container image build.
Fields§
§build_args: Option<Vec<EnvVar>>
buildArgs contains build arguments that will be resolved in the Dockerfile. See https://docs.docker.com/engine/reference/builder/#/arg for more details.
dockerfile_path: Option<String>
dockerfilePath is the path of the Dockerfile that will be used to build the container image, relative to the root of the context (contextDir).
env: Option<Vec<EnvVar>>
env contains additional environment variables you want to pass into a builder container.
force_pull: Option<bool>
forcePull describes if the builder should pull the images from registry prior to building.
from: Option<ObjectReference>
from is reference to an DockerImage, ImageStreamTag, or ImageStreamImage from which the container image should be pulled the resulting image will be used in the FROM line of the Dockerfile for this build.
image_optimization_policy: Option<String>
imageOptimizationPolicy describes what optimizations the system can use when building images to reduce the final size or time spent building the image. The default policy is ‘None’ which means the final build image will be equivalent to an image created by the container image build API. The experimental policy ‘SkipLayers’ will avoid commiting new layers in between each image step, and will fail if the Dockerfile cannot provide compatibility with the ‘None’ policy. An additional experimental policy ‘SkipLayersAndWarn’ is the same as ‘SkipLayers’ but simply warns if compatibility cannot be preserved.
no_cache: Option<bool>
noCache if set to true indicates that the container image build must be executed with the –no-cache=true flag
pull_secret: Option<LocalObjectReference>
pullSecret is the name of a Secret that would be used for setting up the authentication for pulling the container images from the private Docker registries
Trait Implementations§
Source§impl Clone for DockerBuildStrategy
impl Clone for DockerBuildStrategy
Source§fn clone(&self) -> DockerBuildStrategy
fn clone(&self) -> DockerBuildStrategy
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more