DockerfileStage
Handle
interface DockerfileStage { addContainerFiles( resource: IResource, rootDestinationPath: string, logger?: ILogger): DockerfileStage; arg( name: string, defaultValue?: string): DockerfileStage; cmd(command: string[]): DockerfileStage; comment(comment: string): DockerfileStage; copy( source: string, destination: string, chown?: string): DockerfileStage; copyFrom( from: string, source: string, destination: string, chown?: string): DockerfileStage; emptyLine(): DockerfileStage; entrypoint(command: string[]): DockerfileStage; env( name: string, value: string): DockerfileStage; expose(port: number): DockerfileStage; run(command: string): DockerfileStage; runWithMounts( command: string, mounts: string[]): DockerfileStage; user(user: string): DockerfileStage; workDir(path: string): DockerfileStage;}14 members
Methods
method
addContainerFilesAdds COPY --from statements for published container files
addContainerFiles( resource: IResource, rootDestinationPath: string, logger?: ILogger): DockerfileStageParameters
resourceIResourcerootDestinationPathstringloggerILoggeroptionalReturns
DockerfileStagemethod
argAdds an ARG statement to a Dockerfile stage
arg( name: string, defaultValue?: string): DockerfileStageParameters
namestringdefaultValuestringoptionalReturns
DockerfileStagemethod
cmdAdds a CMD statement to a Dockerfile stage
cmd(command: string[]): DockerfileStageParameters
commandstring[]Returns
DockerfileStagemethod
commentAdds a comment to a Dockerfile stage
comment(comment: string): DockerfileStageParameters
commentstringReturns
DockerfileStagemethod
copyAdds a COPY statement to a Dockerfile stage
copy( source: string, destination: string, chown?: string): DockerfileStageParameters
sourcestringdestinationstringchownstringoptionalReturns
DockerfileStagemethod
copyFromAdds a COPY --from statement to a Dockerfile stage
copyFrom( from: string, source: string, destination: string, chown?: string): DockerfileStageParameters
fromstringsourcestringdestinationstringchownstringoptionalReturns
DockerfileStagemethod
emptyLineAdds an empty line to a Dockerfile stage
emptyLine(): DockerfileStageReturns
DockerfileStagemethod
entrypointAdds an ENTRYPOINT statement to a Dockerfile stage
entrypoint(command: string[]): DockerfileStageParameters
commandstring[]Returns
DockerfileStagemethod
envAdds an ENV statement to a Dockerfile stage
env( name: string, value: string): DockerfileStageParameters
namestringvaluestringReturns
DockerfileStagemethod
exposeAdds an EXPOSE statement to a Dockerfile stage
expose(port: number): DockerfileStageParameters
portnumberReturns
DockerfileStagemethod
runAdds a RUN statement to a Dockerfile stage
run(command: string): DockerfileStageParameters
commandstringReturns
DockerfileStagemethod
runWithMountsAdds a RUN statement with mounts to a Dockerfile stage
runWithMounts( command: string, mounts: string[]): DockerfileStageParameters
commandstringmountsstring[]Returns
DockerfileStagemethod
userAdds a USER statement to a Dockerfile stage
user(user: string): DockerfileStageParameters
userstringReturns
DockerfileStagemethod
workDirAdds a WORKDIR statement to a Dockerfile stage
workDir(path: string): DockerfileStageParameters
pathstringReturns
DockerfileStage