azuredevops.ServiceEndpoint.DockerRegistry
Explore with Pulumi AI
Deprecated:
azuredevops.serviceendpoint.DockerRegistry has been deprecated in favor of azuredevops.ServiceEndpointDockerRegistry
Manages a Docker Registry service endpoint within Azure DevOps.
Relevant Links
Example Usage
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureDevOps = Pulumi.AzureDevOps;
return await Deployment.RunAsync(() =>
{
var exampleProject = new AzureDevOps.Project("exampleProject", new()
{
Visibility = "private",
VersionControl = "Git",
WorkItemTemplate = "Agile",
Description = "Managed by Terraform",
});
// dockerhub registry service connection
var exampleServiceEndpointDockerRegistry = new AzureDevOps.ServiceEndpointDockerRegistry("exampleServiceEndpointDockerRegistry", new()
{
ProjectId = exampleProject.Id,
ServiceEndpointName = "Example Docker Hub",
DockerUsername = "example",
DockerEmail = "email@example.com",
DockerPassword = "12345",
RegistryType = "DockerHub",
});
// other docker registry service connection
var example_other = new AzureDevOps.ServiceEndpointDockerRegistry("example-other", new()
{
ProjectId = exampleProject.Id,
ServiceEndpointName = "Example Docker Registry",
DockerRegistryUrl = "https://sample.azurecr.io/v1",
DockerUsername = "sample",
DockerPassword = "12345",
RegistryType = "Others",
});
});
package main
import (
"github.com/pulumi/pulumi-azuredevops/sdk/v2/go/azuredevops"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
exampleProject, err := azuredevops.NewProject(ctx, "exampleProject", &azuredevops.ProjectArgs{
Visibility: pulumi.String("private"),
VersionControl: pulumi.String("Git"),
WorkItemTemplate: pulumi.String("Agile"),
Description: pulumi.String("Managed by Terraform"),
})
if err != nil {
return err
}
_, err = azuredevops.NewServiceEndpointDockerRegistry(ctx, "exampleServiceEndpointDockerRegistry", &azuredevops.ServiceEndpointDockerRegistryArgs{
ProjectId: exampleProject.ID(),
ServiceEndpointName: pulumi.String("Example Docker Hub"),
DockerUsername: pulumi.String("example"),
DockerEmail: pulumi.String("email@example.com"),
DockerPassword: pulumi.String("12345"),
RegistryType: pulumi.String("DockerHub"),
})
if err != nil {
return err
}
_, err = azuredevops.NewServiceEndpointDockerRegistry(ctx, "example-other", &azuredevops.ServiceEndpointDockerRegistryArgs{
ProjectId: exampleProject.ID(),
ServiceEndpointName: pulumi.String("Example Docker Registry"),
DockerRegistry: pulumi.String("https://sample.azurecr.io/v1"),
DockerUsername: pulumi.String("sample"),
DockerPassword: pulumi.String("12345"),
RegistryType: pulumi.String("Others"),
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azuredevops.Project;
import com.pulumi.azuredevops.ProjectArgs;
import com.pulumi.azuredevops.ServiceEndpointDockerRegistry;
import com.pulumi.azuredevops.ServiceEndpointDockerRegistryArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var exampleProject = new Project("exampleProject", ProjectArgs.builder()
.visibility("private")
.versionControl("Git")
.workItemTemplate("Agile")
.description("Managed by Terraform")
.build());
var exampleServiceEndpointDockerRegistry = new ServiceEndpointDockerRegistry("exampleServiceEndpointDockerRegistry", ServiceEndpointDockerRegistryArgs.builder()
.projectId(exampleProject.id())
.serviceEndpointName("Example Docker Hub")
.dockerUsername("example")
.dockerEmail("email@example.com")
.dockerPassword("12345")
.registryType("DockerHub")
.build());
var example_other = new ServiceEndpointDockerRegistry("example-other", ServiceEndpointDockerRegistryArgs.builder()
.projectId(exampleProject.id())
.serviceEndpointName("Example Docker Registry")
.dockerRegistry("https://sample.azurecr.io/v1")
.dockerUsername("sample")
.dockerPassword("12345")
.registryType("Others")
.build());
}
}
import pulumi
import pulumi_azuredevops as azuredevops
example_project = azuredevops.Project("exampleProject",
visibility="private",
version_control="Git",
work_item_template="Agile",
description="Managed by Terraform")
# dockerhub registry service connection
example_service_endpoint_docker_registry = azuredevops.ServiceEndpointDockerRegistry("exampleServiceEndpointDockerRegistry",
project_id=example_project.id,
service_endpoint_name="Example Docker Hub",
docker_username="example",
docker_email="email@example.com",
docker_password="12345",
registry_type="DockerHub")
# other docker registry service connection
example_other = azuredevops.ServiceEndpointDockerRegistry("example-other",
project_id=example_project.id,
service_endpoint_name="Example Docker Registry",
docker_registry="https://sample.azurecr.io/v1",
docker_username="sample",
docker_password="12345",
registry_type="Others")
import * as pulumi from "@pulumi/pulumi";
import * as azuredevops from "@pulumi/azuredevops";
const exampleProject = new azuredevops.Project("exampleProject", {
visibility: "private",
versionControl: "Git",
workItemTemplate: "Agile",
description: "Managed by Terraform",
});
// dockerhub registry service connection
const exampleServiceEndpointDockerRegistry = new azuredevops.ServiceEndpointDockerRegistry("exampleServiceEndpointDockerRegistry", {
projectId: exampleProject.id,
serviceEndpointName: "Example Docker Hub",
dockerUsername: "example",
dockerEmail: "email@example.com",
dockerPassword: "12345",
registryType: "DockerHub",
});
// other docker registry service connection
const example_other = new azuredevops.ServiceEndpointDockerRegistry("example-other", {
projectId: exampleProject.id,
serviceEndpointName: "Example Docker Registry",
dockerRegistry: "https://sample.azurecr.io/v1",
dockerUsername: "sample",
dockerPassword: "12345",
registryType: "Others",
});
resources:
exampleProject:
type: azuredevops:Project
properties:
visibility: private
versionControl: Git
workItemTemplate: Agile
description: Managed by Terraform
# dockerhub registry service connection
exampleServiceEndpointDockerRegistry:
type: azuredevops:ServiceEndpointDockerRegistry
properties:
projectId: ${exampleProject.id}
serviceEndpointName: Example Docker Hub
dockerUsername: example
dockerEmail: email@example.com
dockerPassword: '12345'
registryType: DockerHub
# other docker registry service connection
example-other:
type: azuredevops:ServiceEndpointDockerRegistry
properties:
projectId: ${exampleProject.id}
serviceEndpointName: Example Docker Registry
dockerRegistry: https://sample.azurecr.io/v1
dockerUsername: sample
dockerPassword: '12345'
registryType: Others
Create DockerRegistry Resource
new DockerRegistry(name: string, args: DockerRegistryArgs, opts?: CustomResourceOptions);
@overload
def DockerRegistry(resource_name: str,
opts: Optional[ResourceOptions] = None,
authorization: Optional[Mapping[str, str]] = None,
description: Optional[str] = None,
docker_email: Optional[str] = None,
docker_password: Optional[str] = None,
docker_registry: Optional[str] = None,
docker_username: Optional[str] = None,
project_id: Optional[str] = None,
registry_type: Optional[str] = None,
service_endpoint_name: Optional[str] = None)
@overload
def DockerRegistry(resource_name: str,
args: DockerRegistryArgs,
opts: Optional[ResourceOptions] = None)
func NewDockerRegistry(ctx *Context, name string, args DockerRegistryArgs, opts ...ResourceOption) (*DockerRegistry, error)
public DockerRegistry(string name, DockerRegistryArgs args, CustomResourceOptions? opts = null)
public DockerRegistry(String name, DockerRegistryArgs args)
public DockerRegistry(String name, DockerRegistryArgs args, CustomResourceOptions options)
type: azuredevops:ServiceEndpoint:DockerRegistry
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args DockerRegistryArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args DockerRegistryArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args DockerRegistryArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args DockerRegistryArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args DockerRegistryArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
DockerRegistry Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
The DockerRegistry resource accepts the following input properties:
- Docker
Registry stringUrl The URL of the Docker registry. (Default: "https://index.docker.io/v1/")
- Project
Id string The ID of the project.
- Registry
Type string Can be "DockerHub" or "Others" (Default "DockerHub")
- Service
Endpoint stringName The name you will use to refer to this service connection in task inputs.
- Dictionary<string, string>
- Description string
- Docker
Email string The email for Docker account user.
- Docker
Password string The password for the account user identified above.
- Docker
Username string The identifier of the Docker account user.
- Docker
Registry string The URL of the Docker registry. (Default: "https://index.docker.io/v1/")
- Project
Id string The ID of the project.
- Registry
Type string Can be "DockerHub" or "Others" (Default "DockerHub")
- Service
Endpoint stringName The name you will use to refer to this service connection in task inputs.
- map[string]string
- Description string
- Docker
Email string The email for Docker account user.
- Docker
Password string The password for the account user identified above.
- Docker
Username string The identifier of the Docker account user.
- docker
Registry String The URL of the Docker registry. (Default: "https://index.docker.io/v1/")
- project
Id String The ID of the project.
- registry
Type String Can be "DockerHub" or "Others" (Default "DockerHub")
- service
Endpoint StringName The name you will use to refer to this service connection in task inputs.
- Map<String,String>
- description String
- docker
Email String The email for Docker account user.
- docker
Password String The password for the account user identified above.
- docker
Username String The identifier of the Docker account user.
- docker
Registry string The URL of the Docker registry. (Default: "https://index.docker.io/v1/")
- project
Id string The ID of the project.
- registry
Type string Can be "DockerHub" or "Others" (Default "DockerHub")
- service
Endpoint stringName The name you will use to refer to this service connection in task inputs.
- {[key: string]: string}
- description string
- docker
Email string The email for Docker account user.
- docker
Password string The password for the account user identified above.
- docker
Username string The identifier of the Docker account user.
- docker_
registry str The URL of the Docker registry. (Default: "https://index.docker.io/v1/")
- project_
id str The ID of the project.
- registry_
type str Can be "DockerHub" or "Others" (Default "DockerHub")
- service_
endpoint_ strname The name you will use to refer to this service connection in task inputs.
- Mapping[str, str]
- description str
- docker_
email str The email for Docker account user.
- docker_
password str The password for the account user identified above.
- docker_
username str The identifier of the Docker account user.
- docker
Registry String The URL of the Docker registry. (Default: "https://index.docker.io/v1/")
- project
Id String The ID of the project.
- registry
Type String Can be "DockerHub" or "Others" (Default "DockerHub")
- service
Endpoint StringName The name you will use to refer to this service connection in task inputs.
- Map<String>
- description String
- docker
Email String The email for Docker account user.
- docker
Password String The password for the account user identified above.
- docker
Username String The identifier of the Docker account user.
Outputs
All input properties are implicitly available as output properties. Additionally, the DockerRegistry resource produces the following output properties:
- Id string
The provider-assigned unique ID for this managed resource.
- Id string
The provider-assigned unique ID for this managed resource.
- id String
The provider-assigned unique ID for this managed resource.
- id string
The provider-assigned unique ID for this managed resource.
- id str
The provider-assigned unique ID for this managed resource.
- id String
The provider-assigned unique ID for this managed resource.
Look up Existing DockerRegistry Resource
Get an existing DockerRegistry resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: DockerRegistryState, opts?: CustomResourceOptions): DockerRegistry
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
authorization: Optional[Mapping[str, str]] = None,
description: Optional[str] = None,
docker_email: Optional[str] = None,
docker_password: Optional[str] = None,
docker_registry: Optional[str] = None,
docker_username: Optional[str] = None,
project_id: Optional[str] = None,
registry_type: Optional[str] = None,
service_endpoint_name: Optional[str] = None) -> DockerRegistry
func GetDockerRegistry(ctx *Context, name string, id IDInput, state *DockerRegistryState, opts ...ResourceOption) (*DockerRegistry, error)
public static DockerRegistry Get(string name, Input<string> id, DockerRegistryState? state, CustomResourceOptions? opts = null)
public static DockerRegistry get(String name, Output<String> id, DockerRegistryState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Dictionary<string, string>
- Description string
- Docker
Email string The email for Docker account user.
- Docker
Password string The password for the account user identified above.
- Docker
Registry stringUrl The URL of the Docker registry. (Default: "https://index.docker.io/v1/")
- Docker
Username string The identifier of the Docker account user.
- Project
Id string The ID of the project.
- Registry
Type string Can be "DockerHub" or "Others" (Default "DockerHub")
- Service
Endpoint stringName The name you will use to refer to this service connection in task inputs.
- map[string]string
- Description string
- Docker
Email string The email for Docker account user.
- Docker
Password string The password for the account user identified above.
- Docker
Registry string The URL of the Docker registry. (Default: "https://index.docker.io/v1/")
- Docker
Username string The identifier of the Docker account user.
- Project
Id string The ID of the project.
- Registry
Type string Can be "DockerHub" or "Others" (Default "DockerHub")
- Service
Endpoint stringName The name you will use to refer to this service connection in task inputs.
- Map<String,String>
- description String
- docker
Email String The email for Docker account user.
- docker
Password String The password for the account user identified above.
- docker
Registry String The URL of the Docker registry. (Default: "https://index.docker.io/v1/")
- docker
Username String The identifier of the Docker account user.
- project
Id String The ID of the project.
- registry
Type String Can be "DockerHub" or "Others" (Default "DockerHub")
- service
Endpoint StringName The name you will use to refer to this service connection in task inputs.
- {[key: string]: string}
- description string
- docker
Email string The email for Docker account user.
- docker
Password string The password for the account user identified above.
- docker
Registry string The URL of the Docker registry. (Default: "https://index.docker.io/v1/")
- docker
Username string The identifier of the Docker account user.
- project
Id string The ID of the project.
- registry
Type string Can be "DockerHub" or "Others" (Default "DockerHub")
- service
Endpoint stringName The name you will use to refer to this service connection in task inputs.
- Mapping[str, str]
- description str
- docker_
email str The email for Docker account user.
- docker_
password str The password for the account user identified above.
- docker_
registry str The URL of the Docker registry. (Default: "https://index.docker.io/v1/")
- docker_
username str The identifier of the Docker account user.
- project_
id str The ID of the project.
- registry_
type str Can be "DockerHub" or "Others" (Default "DockerHub")
- service_
endpoint_ strname The name you will use to refer to this service connection in task inputs.
- Map<String>
- description String
- docker
Email String The email for Docker account user.
- docker
Password String The password for the account user identified above.
- docker
Registry String The URL of the Docker registry. (Default: "https://index.docker.io/v1/")
- docker
Username String The identifier of the Docker account user.
- project
Id String The ID of the project.
- registry
Type String Can be "DockerHub" or "Others" (Default "DockerHub")
- service
Endpoint StringName The name you will use to refer to this service connection in task inputs.
Import
Azure DevOps Service Endpoint Docker Registry can be imported using projectID/serviceEndpointID or projectName/serviceEndpointID
$ pulumi import azuredevops:ServiceEndpoint/dockerRegistry:DockerRegistry example 00000000-0000-0000-0000-000000000000/00000000-0000-0000-0000-000000000000
Package Details
- Repository
- Azure DevOps pulumi/pulumi-azuredevops
- License
- Apache-2.0
- Notes
This Pulumi package is based on the
azuredevops
Terraform Provider.