Class DockerBuildRequest
- java.lang.Object
-
- com.azure.resourcemanager.containerregistry.models.RunRequest
-
- com.azure.resourcemanager.containerregistry.models.DockerBuildRequest
-
public final class DockerBuildRequest extends RunRequest
The parameters for a docker quick build.
-
-
Constructor Summary
Constructors Constructor Description DockerBuildRequest()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description AgentPropertiesagentConfiguration()Get the agentConfiguration property: The machine configuration of the run agent.List<Argument>arguments()Get the arguments property: The collection of override arguments to be used when executing the run.Credentialscredentials()Get the credentials property: The properties that describes a set of credentials that will be used when this run is invoked.StringdockerFilePath()Get the dockerFilePath property: The Docker file path relative to the source location.List<String>imageNames()Get the imageNames property: The fully qualified image names including the repository and tag.BooleanisPushEnabled()Get the isPushEnabled property: The value of this property indicates whether the image built should be pushed to the registry or not.BooleannoCache()Get the noCache property: The value of this property indicates whether the image cache is enabled or not.PlatformPropertiesplatform()Get the platform property: The platform properties against which the run has to happen.StringsourceLocation()Get the sourceLocation property: The URL(absolute or relative) of the source context.Stringtarget()Get the target property: The name of the target build stage for the docker build.Integertimeout()Get the timeout property: Run timeout in seconds.voidvalidate()Validates the instance.DockerBuildRequestwithAgentConfiguration(AgentProperties agentConfiguration)Set the agentConfiguration property: The machine configuration of the run agent.DockerBuildRequestwithAgentPoolName(String agentPoolName)Set the agentPoolName property: The dedicated agent pool for the run.DockerBuildRequestwithArguments(List<Argument> arguments)Set the arguments property: The collection of override arguments to be used when executing the run.DockerBuildRequestwithCredentials(Credentials credentials)Set the credentials property: The properties that describes a set of credentials that will be used when this run is invoked.DockerBuildRequestwithDockerFilePath(String dockerFilePath)Set the dockerFilePath property: The Docker file path relative to the source location.DockerBuildRequestwithImageNames(List<String> imageNames)Set the imageNames property: The fully qualified image names including the repository and tag.DockerBuildRequestwithIsArchiveEnabled(Boolean isArchiveEnabled)Set the isArchiveEnabled property: The value that indicates whether archiving is enabled for the run or not.DockerBuildRequestwithIsPushEnabled(Boolean isPushEnabled)Set the isPushEnabled property: The value of this property indicates whether the image built should be pushed to the registry or not.DockerBuildRequestwithLogTemplate(String logTemplate)Set the logTemplate property: The template that describes the repository and tag information for run log artifact.DockerBuildRequestwithNoCache(Boolean noCache)Set the noCache property: The value of this property indicates whether the image cache is enabled or not.DockerBuildRequestwithPlatform(PlatformProperties platform)Set the platform property: The platform properties against which the run has to happen.DockerBuildRequestwithSourceLocation(String sourceLocation)Set the sourceLocation property: The URL(absolute or relative) of the source context.DockerBuildRequestwithTarget(String target)Set the target property: The name of the target build stage for the docker build.DockerBuildRequestwithTimeout(Integer timeout)Set the timeout property: Run timeout in seconds.-
Methods inherited from class com.azure.resourcemanager.containerregistry.models.RunRequest
agentPoolName, isArchiveEnabled, logTemplate
-
-
-
-
Method Detail
-
imageNames
public List<String> imageNames()
Get the imageNames property: The fully qualified image names including the repository and tag.- Returns:
- the imageNames value.
-
withImageNames
public DockerBuildRequest withImageNames(List<String> imageNames)
Set the imageNames property: The fully qualified image names including the repository and tag.- Parameters:
imageNames- the imageNames value to set.- Returns:
- the DockerBuildRequest object itself.
-
isPushEnabled
public Boolean isPushEnabled()
Get the isPushEnabled property: The value of this property indicates whether the image built should be pushed to the registry or not.- Returns:
- the isPushEnabled value.
-
withIsPushEnabled
public DockerBuildRequest withIsPushEnabled(Boolean isPushEnabled)
Set the isPushEnabled property: The value of this property indicates whether the image built should be pushed to the registry or not.- Parameters:
isPushEnabled- the isPushEnabled value to set.- Returns:
- the DockerBuildRequest object itself.
-
noCache
public Boolean noCache()
Get the noCache property: The value of this property indicates whether the image cache is enabled or not.- Returns:
- the noCache value.
-
withNoCache
public DockerBuildRequest withNoCache(Boolean noCache)
Set the noCache property: The value of this property indicates whether the image cache is enabled or not.- Parameters:
noCache- the noCache value to set.- Returns:
- the DockerBuildRequest object itself.
-
dockerFilePath
public String dockerFilePath()
Get the dockerFilePath property: The Docker file path relative to the source location.- Returns:
- the dockerFilePath value.
-
withDockerFilePath
public DockerBuildRequest withDockerFilePath(String dockerFilePath)
Set the dockerFilePath property: The Docker file path relative to the source location.- Parameters:
dockerFilePath- the dockerFilePath value to set.- Returns:
- the DockerBuildRequest object itself.
-
target
public String target()
Get the target property: The name of the target build stage for the docker build.- Returns:
- the target value.
-
withTarget
public DockerBuildRequest withTarget(String target)
Set the target property: The name of the target build stage for the docker build.- Parameters:
target- the target value to set.- Returns:
- the DockerBuildRequest object itself.
-
arguments
public List<Argument> arguments()
Get the arguments property: The collection of override arguments to be used when executing the run.- Returns:
- the arguments value.
-
withArguments
public DockerBuildRequest withArguments(List<Argument> arguments)
Set the arguments property: The collection of override arguments to be used when executing the run.- Parameters:
arguments- the arguments value to set.- Returns:
- the DockerBuildRequest object itself.
-
timeout
public Integer timeout()
Get the timeout property: Run timeout in seconds.- Returns:
- the timeout value.
-
withTimeout
public DockerBuildRequest withTimeout(Integer timeout)
Set the timeout property: Run timeout in seconds.- Parameters:
timeout- the timeout value to set.- Returns:
- the DockerBuildRequest object itself.
-
platform
public PlatformProperties platform()
Get the platform property: The platform properties against which the run has to happen.- Returns:
- the platform value.
-
withPlatform
public DockerBuildRequest withPlatform(PlatformProperties platform)
Set the platform property: The platform properties against which the run has to happen.- Parameters:
platform- the platform value to set.- Returns:
- the DockerBuildRequest object itself.
-
agentConfiguration
public AgentProperties agentConfiguration()
Get the agentConfiguration property: The machine configuration of the run agent.- Returns:
- the agentConfiguration value.
-
withAgentConfiguration
public DockerBuildRequest withAgentConfiguration(AgentProperties agentConfiguration)
Set the agentConfiguration property: The machine configuration of the run agent.- Parameters:
agentConfiguration- the agentConfiguration value to set.- Returns:
- the DockerBuildRequest object itself.
-
sourceLocation
public String sourceLocation()
Get the sourceLocation property: The URL(absolute or relative) of the source context. It can be an URL to a tar or git repository. If it is relative URL, the relative path should be obtained from calling listBuildSourceUploadUrl API.- Returns:
- the sourceLocation value.
-
withSourceLocation
public DockerBuildRequest withSourceLocation(String sourceLocation)
Set the sourceLocation property: The URL(absolute or relative) of the source context. It can be an URL to a tar or git repository. If it is relative URL, the relative path should be obtained from calling listBuildSourceUploadUrl API.- Parameters:
sourceLocation- the sourceLocation value to set.- Returns:
- the DockerBuildRequest object itself.
-
credentials
public Credentials credentials()
Get the credentials property: The properties that describes a set of credentials that will be used when this run is invoked.- Returns:
- the credentials value.
-
withCredentials
public DockerBuildRequest withCredentials(Credentials credentials)
Set the credentials property: The properties that describes a set of credentials that will be used when this run is invoked.- Parameters:
credentials- the credentials value to set.- Returns:
- the DockerBuildRequest object itself.
-
withIsArchiveEnabled
public DockerBuildRequest withIsArchiveEnabled(Boolean isArchiveEnabled)
Set the isArchiveEnabled property: The value that indicates whether archiving is enabled for the run or not.- Overrides:
withIsArchiveEnabledin classRunRequest- Parameters:
isArchiveEnabled- the isArchiveEnabled value to set.- Returns:
- the RunRequest object itself.
-
withAgentPoolName
public DockerBuildRequest withAgentPoolName(String agentPoolName)
Set the agentPoolName property: The dedicated agent pool for the run.- Overrides:
withAgentPoolNamein classRunRequest- Parameters:
agentPoolName- the agentPoolName value to set.- Returns:
- the RunRequest object itself.
-
withLogTemplate
public DockerBuildRequest withLogTemplate(String logTemplate)
Set the logTemplate property: The template that describes the repository and tag information for run log artifact.- Overrides:
withLogTemplatein classRunRequest- Parameters:
logTemplate- the logTemplate value to set.- Returns:
- the RunRequest object itself.
-
validate
public void validate()
Validates the instance.- Overrides:
validatein classRunRequest- Throws:
IllegalArgumentException- thrown if the instance is not valid.
-
-