Interface ContainerBuild

ContainerBuild may be used to specify detailed instructions about how to build a container.

interface ContainerBuild {
    args?: {
        [key: string]: string;
    };
    cacheFrom?: boolean | CacheFrom;
    context?: string;
    dockerfile?: string;
}

Properties

args?: {
    [key: string]: string;
}

An optional map of named build-time argument variables to set during the Docker build. This flag allows you to pass built-time variables that can be accessed like environment variables inside the RUN instruction.

Type declaration

  • [key: string]: string
cacheFrom?: boolean | CacheFrom

An optional CacheFrom object with information about the build stages to use for the Docker build cache. This parameter maps to the --cache-from argument to the Docker CLI. If this parameter is true, only the final image will be pulled and passed to --cache-from; if it is a CacheFrom object, the stages named therein will also be pulled and passed to --cache-from.

context?: string

context is a path to a directory to use for the Docker build context, usually the directory in which the Dockerfile resides (although dockerfile may be used to choose a custom location independent of this choice). If not specified, the context defaults to the current working directory; if a relative path is used, it is relative to the current working directory that Pulumi is evaluating.

dockerfile?: string

dockerfile may be used to override the default Dockerfile name and/or location. By default, it is assumed to be a file named Dockerfile in the root of the build context.

Generated using TypeDoc