Microsoft.ContainerRegistry registries/credentialSets

Bicep resource definition

The registries/credentialSets resource type can be deployed with operations that target:

For a list of changed properties in each API version, see change log.

Resource format

To create a Microsoft.ContainerRegistry/registries/credentialSets resource, add the following Bicep to your template.

resource symbolicname 'Microsoft.ContainerRegistry/registries/credentialSets@2023-01-01-preview' = {
  name: 'string'
  parent: resourceSymbolicName
  identity: {
    principalId: 'string'
    tenantId: 'string'
    type: 'string'
    userAssignedIdentities: {}
  }
  properties: {
    authCredentials: [
      {
        name: 'Credential1'
        passwordSecretIdentifier: 'string'
        usernameSecretIdentifier: 'string'
      }
    ]
    loginServer: 'string'
  }
}

Property values

registries/credentialSets

Name Description Value
name The resource name

See how to set names and types for child resources in Bicep.
string (required)
parent In Bicep, you can specify the parent resource for a child resource. You only need to add this property when the child resource is declared outside of the parent resource.

For more information, see Child resource outside parent resource.
Symbolic name for resource of type: registries
identity Identities associated with the resource. This is used to access the KeyVault secrets. IdentityProperties
properties The properties of the credential set. CredentialSetProperties

IdentityProperties

Name Description Value
principalId The principal ID of resource identity. string
tenantId The tenant ID of resource. string
type The identity type. 'None'
'SystemAssigned'
'SystemAssigned, UserAssigned'
'UserAssigned'
userAssignedIdentities The list of user identities associated with the resource. The user identity
dictionary key references will be ARM resource ids in the form:
'/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/
providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}'.
object

CredentialSetProperties

Name Description Value
authCredentials List of authentication credentials stored for an upstream.
Usually consists of a primary and an optional secondary credential.
AuthCredential[]
loginServer The credentials are stored for this upstream or login server. string

AuthCredential

Name Description Value
name The name of the credential. 'Credential1'
passwordSecretIdentifier KeyVault Secret URI for accessing the password. string
usernameSecretIdentifier KeyVault Secret URI for accessing the username. string

ARM template resource definition

The registries/credentialSets resource type can be deployed with operations that target:

For a list of changed properties in each API version, see change log.

Resource format

To create a Microsoft.ContainerRegistry/registries/credentialSets resource, add the following JSON to your template.

{
  "type": "Microsoft.ContainerRegistry/registries/credentialSets",
  "apiVersion": "2023-01-01-preview",
  "name": "string",
  "identity": {
    "principalId": "string",
    "tenantId": "string",
    "type": "string",
    "userAssignedIdentities": {}
  },
  "properties": {
    "authCredentials": [
      {
        "name": "Credential1",
        "passwordSecretIdentifier": "string",
        "usernameSecretIdentifier": "string"
      }
    ],
    "loginServer": "string"
  }
}

Property values

registries/credentialSets

Name Description Value
type The resource type 'Microsoft.ContainerRegistry/registries/credentialSets'
apiVersion The resource api version '2023-01-01-preview'
name The resource name

See how to set names and types for child resources in JSON ARM templates.
string (required)
identity Identities associated with the resource. This is used to access the KeyVault secrets. IdentityProperties
properties The properties of the credential set. CredentialSetProperties

IdentityProperties

Name Description Value
principalId The principal ID of resource identity. string
tenantId The tenant ID of resource. string
type The identity type. 'None'
'SystemAssigned'
'SystemAssigned, UserAssigned'
'UserAssigned'
userAssignedIdentities The list of user identities associated with the resource. The user identity
dictionary key references will be ARM resource ids in the form:
'/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/
providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}'.
object

CredentialSetProperties

Name Description Value
authCredentials List of authentication credentials stored for an upstream.
Usually consists of a primary and an optional secondary credential.
AuthCredential[]
loginServer The credentials are stored for this upstream or login server. string

AuthCredential

Name Description Value
name The name of the credential. 'Credential1'
passwordSecretIdentifier KeyVault Secret URI for accessing the password. string
usernameSecretIdentifier KeyVault Secret URI for accessing the username. string

Terraform (AzAPI provider) resource definition

The registries/credentialSets resource type can be deployed with operations that target:

  • Resource groups

For a list of changed properties in each API version, see change log.

Resource format

To create a Microsoft.ContainerRegistry/registries/credentialSets resource, add the following Terraform to your template.

resource "azapi_resource" "symbolicname" {
  type = "Microsoft.ContainerRegistry/registries/credentialSets@2023-01-01-preview"
  name = "string"
  parent_id = "string"
  identity {
    type = "string"
    identity_ids = []
  }
  body = jsonencode({
    properties = {
      authCredentials = [
        {
          name = "Credential1"
          passwordSecretIdentifier = "string"
          usernameSecretIdentifier = "string"
        }
      ]
      loginServer = "string"
    }
  })
}

Property values

registries/credentialSets

Name Description Value
type The resource type "Microsoft.ContainerRegistry/registries/credentialSets@2023-01-01-preview"
name The resource name string (required)
parent_id The ID of the resource that is the parent for this resource. ID for resource of type: registries
identity Identities associated with the resource. This is used to access the KeyVault secrets. IdentityProperties
properties The properties of the credential set. CredentialSetProperties

IdentityProperties

Name Description Value
type The identity type. "SystemAssigned"
"SystemAssigned, UserAssigned"
"UserAssigned"
identity_ids The list of user identities associated with the resource. The user identity
dictionary key references will be ARM resource ids in the form:
'/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/
providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}'.
Array of user identity IDs.

CredentialSetProperties

Name Description Value
authCredentials List of authentication credentials stored for an upstream.
Usually consists of a primary and an optional secondary credential.
AuthCredential[]
loginServer The credentials are stored for this upstream or login server. string

AuthCredential

Name Description Value
name The name of the credential. "Credential1"
passwordSecretIdentifier KeyVault Secret URI for accessing the password. string
usernameSecretIdentifier KeyVault Secret URI for accessing the username. string