DockerfileStage
Classnet10.0
Represents a stage within a multi-stage Dockerfile.
namespace Aspire.Hosting.ApplicationModel.Docker;
public class DockerfileStage : Aspire.Hosting.ApplicationModel.Docker.DockerfileStatement{ // ...}20 members
Constructors1
Section titled Constructors Initializes a new instance of the
DockerfileStage class. Properties2
Section titled PropertiesView all properties
Methods17
Section titled MethodsArg(string, string)experimental Adds an ARG statement to define a build-time variable with a default value.
Comment(string)experimental Adds a comment to the Dockerfile. Multi-line comments are supported.
Copy(string, string)experimental Adds a COPY statement to copy files from the build context.
Copy(string, string, string)experimental Adds a COPY statement to copy files with ownership change.
CopyFrom(string, string, string)experimental Adds a COPY statement to copy files from another stage.
CopyFrom(string, string, string, string)experimental Adds a COPY statement to copy files from another stage with ownership change.
Entrypoint(string[])experimental Adds an ENTRYPOINT statement to set the container entrypoint.
Env(string, string)experimental Adds an ENV statement to set an environment variable.
RunWithMounts(string, string[])experimental Adds a RUN statement with mount options for BuildKit.
User(string)experimental Adds a USER statement to set the user for subsequent commands.
Task Writes the statement to the specified writer.