Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,80 @@
/**
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
*/

package com.microsoft.azure.management.containerregistry.v2018_09_01;

import java.util.Map;
import com.fasterxml.jackson.annotation.JsonProperty;

/**
* The parameters that describes a set of credentials that will be used when a
* run is invoked.
*/
public class Credentials {
/**
* Describes the credential parameters for accessing the source registry.
*/
@JsonProperty(value = "sourceRegistry")
private SourceRegistryCredentials sourceRegistry;

/**
* Describes the credential parameters for accessing other custom
* registries. The key
* for the dictionary item will be the registry login server
* (myregistry.azurecr.io) and
* the value of the item will be the registry credentials for accessing the
* registry.
*/
@JsonProperty(value = "customRegistries")
private Map<String, CustomRegistryCredentials> customRegistries;

/**
* Get describes the credential parameters for accessing the source registry.
*
* @return the sourceRegistry value
*/
public SourceRegistryCredentials sourceRegistry() {
return this.sourceRegistry;
}

/**
* Set describes the credential parameters for accessing the source registry.
*
* @param sourceRegistry the sourceRegistry value to set
* @return the Credentials object itself.
*/
public Credentials withSourceRegistry(SourceRegistryCredentials sourceRegistry) {
this.sourceRegistry = sourceRegistry;
return this;
}

/**
* Get describes the credential parameters for accessing other custom registries. The key
for the dictionary item will be the registry login server (myregistry.azurecr.io) and
the value of the item will be the registry credentials for accessing the registry.
*
* @return the customRegistries value
*/
public Map<String, CustomRegistryCredentials> customRegistries() {
return this.customRegistries;
}

/**
* Set describes the credential parameters for accessing other custom registries. The key
for the dictionary item will be the registry login server (myregistry.azurecr.io) and
the value of the item will be the registry credentials for accessing the registry.
*
* @param customRegistries the customRegistries value to set
* @return the Credentials object itself.
*/
public Credentials withCustomRegistries(Map<String, CustomRegistryCredentials> customRegistries) {
this.customRegistries = customRegistries;
return this;
}

}
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
/**
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
*/

package com.microsoft.azure.management.containerregistry.v2018_09_01;

import com.fasterxml.jackson.annotation.JsonProperty;

/**
* Describes the credentials that will be used to access a custom registry
* during a run.
*/
public class CustomRegistryCredentials {
/**
* The username for logging into the custom registry.
*/
@JsonProperty(value = "userName")
private SecretObject userName;

/**
* The password for logging into the custom registry. The password is a
* secret
* object that allows multiple ways of providing the value for it.
*/
@JsonProperty(value = "password")
private SecretObject password;

/**
* Get the username for logging into the custom registry.
*
* @return the userName value
*/
public SecretObject userName() {
return this.userName;
}

/**
* Set the username for logging into the custom registry.
*
* @param userName the userName value to set
* @return the CustomRegistryCredentials object itself.
*/
public CustomRegistryCredentials withUserName(SecretObject userName) {
this.userName = userName;
return this;
}

/**
* Get the password for logging into the custom registry. The password is a secret
object that allows multiple ways of providing the value for it.
*
* @return the password value
*/
public SecretObject password() {
return this.password;
}

/**
* Set the password for logging into the custom registry. The password is a secret
object that allows multiple ways of providing the value for it.
*
* @param password the password value to set
* @return the CustomRegistryCredentials object itself.
*/
public CustomRegistryCredentials withPassword(SecretObject password) {
this.password = password;
return this;
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,12 @@ public class DockerBuildRequest extends RunRequest {
@JsonProperty(value = "dockerFilePath", required = true)
private String dockerFilePath;

/**
* The name of the target build stage for the docker build.
*/
@JsonProperty(value = "target")
private String target;

/**
* The collection of override arguments to be used when executing the run.
*/
Expand Down Expand Up @@ -78,6 +84,13 @@ public class DockerBuildRequest extends RunRequest {
@JsonProperty(value = "sourceLocation")
private String sourceLocation;

/**
* The properties that describes a set of credentials that will be used
* when this run is invoked.
*/
@JsonProperty(value = "credentials")
private Credentials credentials;

/**
* Get the fully qualified image names including the repository and tag.
*
Expand Down Expand Up @@ -158,6 +171,26 @@ public DockerBuildRequest withDockerFilePath(String dockerFilePath) {
return this;
}

/**
* Get the name of the target build stage for the docker build.
*
* @return the target value
*/
public String target() {
return this.target;
}

/**
* Set the name of the target build stage for the docker build.
*
* @param target the target value to set
* @return the DockerBuildRequest object itself.
*/
public DockerBuildRequest withTarget(String target) {
this.target = target;
return this;
}

/**
* Get the collection of override arguments to be used when executing the run.
*
Expand Down Expand Up @@ -260,4 +293,24 @@ public DockerBuildRequest withSourceLocation(String sourceLocation) {
return this;
}

/**
* Get the properties that describes a set of credentials that will be used when this run is invoked.
*
* @return the credentials value
*/
public Credentials credentials() {
return this.credentials;
}

/**
* Set the properties that describes a set of credentials that will be used when this run is invoked.
*
* @param credentials the credentials value to set
* @return the DockerBuildRequest object itself.
*/
public DockerBuildRequest withCredentials(Credentials credentials) {
this.credentials = credentials;
return this;
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,12 @@ public class DockerBuildStep extends TaskStepProperties {
@JsonProperty(value = "dockerFilePath", required = true)
private String dockerFilePath;

/**
* The name of the target build stage for the docker build.
*/
@JsonProperty(value = "target")
private String target;

/**
* The collection of override arguments to be used when executing this
* build step.
Expand Down Expand Up @@ -132,6 +138,26 @@ public DockerBuildStep withDockerFilePath(String dockerFilePath) {
return this;
}

/**
* Get the name of the target build stage for the docker build.
*
* @return the target value
*/
public String target() {
return this.target;
}

/**
* Set the name of the target build stage for the docker build.
*
* @param target the target value to set
* @return the DockerBuildStep object itself.
*/
public DockerBuildStep withTarget(String target) {
this.target = target;
return this;
}

/**
* Get the collection of override arguments to be used when executing this build step.
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,12 @@ public class DockerBuildStepUpdateParameters extends TaskStepUpdateParameters {
@JsonProperty(value = "arguments")
private List<Argument> arguments;

/**
* The name of the target build stage for the docker build.
*/
@JsonProperty(value = "target")
private String target;

/**
* Get the fully qualified image names including the repository and tag.
*
Expand Down Expand Up @@ -152,4 +158,24 @@ public DockerBuildStepUpdateParameters withArguments(List<Argument> arguments) {
return this;
}

/**
* Get the name of the target build stage for the docker build.
*
* @return the target value
*/
public String target() {
return this.target;
}

/**
* Set the name of the target build stage for the docker build.
*
* @param target the target value to set
* @return the DockerBuildStepUpdateParameters object itself.
*/
public DockerBuildStepUpdateParameters withTarget(String target) {
this.target = target;
return this;
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,13 @@ public class EncodedTaskRunRequest extends RunRequest {
@JsonProperty(value = "sourceLocation")
private String sourceLocation;

/**
* The properties that describes a set of credentials that will be used
* when this run is invoked.
*/
@JsonProperty(value = "credentials")
private Credentials credentials;

/**
* Get base64 encoded value of the template/definition file content.
*
Expand Down Expand Up @@ -207,4 +214,24 @@ public EncodedTaskRunRequest withSourceLocation(String sourceLocation) {
return this;
}

/**
* Get the properties that describes a set of credentials that will be used when this run is invoked.
*
* @return the credentials value
*/
public Credentials credentials() {
return this.credentials;
}

/**
* Set the properties that describes a set of credentials that will be used when this run is invoked.
*
* @param credentials the credentials value to set
* @return the EncodedTaskRunRequest object itself.
*/
public EncodedTaskRunRequest withCredentials(Credentials credentials) {
this.credentials = credentials;
return this;
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,13 @@ public class FileTaskRunRequest extends RunRequest {
@JsonProperty(value = "sourceLocation")
private String sourceLocation;

/**
* The properties that describes a set of credentials that will be used
* when this run is invoked.
*/
@JsonProperty(value = "credentials")
private Credentials credentials;

/**
* Get the template/definition file path relative to the source.
*
Expand Down Expand Up @@ -207,4 +214,24 @@ public FileTaskRunRequest withSourceLocation(String sourceLocation) {
return this;
}

/**
* Get the properties that describes a set of credentials that will be used when this run is invoked.
*
* @return the credentials value
*/
public Credentials credentials() {
return this.credentials;
}

/**
* Set the properties that describes a set of credentials that will be used when this run is invoked.
*
* @param credentials the credentials value to set
* @return the FileTaskRunRequest object itself.
*/
public FileTaskRunRequest withCredentials(Credentials credentials) {
this.credentials = credentials;
return this;
}

}
Loading