Skip to content

Use valid App Configuration store names#

Operational Excellence · App Configuration · Rule · 2020_12 · Awareness

App Configuration store names should meet naming requirements.

Description#

When naming Azure resources, resource names must meet service requirements. The requirements for App Configuration store names are:

  • Between 5 and 50 characters long.
  • Alphanumerics and hyphens.
  • Start and end with a letter or number.
  • App Configuration store names must be unique within a resource group.

Recommendation#

Consider using names that meet App Configuration store naming requirements. Additionally consider naming resources with a standard naming convention.

Examples#

Configure with Azure template#

To deploy configuration stores that pass this rule:

  • Set name to a value that meets the requirements.

For example:

Azure Template snippet
{
  "type": "Microsoft.AppConfiguration/configurationStores",
  "apiVersion": "2022-05-01",
  "name": "[parameters('name')]",
  "location": "[parameters('location')]",
  "sku": {
    "name": "standard"
  },
  "properties": {
    "disableLocalAuth": true,
    "enablePurgeProtection": true
  }
}

Configure with Bicep#

To deploy configuration stores that pass this rule:

  • Set name to a value that meets the requirements.

For example:

Azure Bicep snippet
resource store 'Microsoft.AppConfiguration/configurationStores@2022-05-01' = {
  name: name
  location: location
  sku: {
    name: 'standard'
  }
  properties: {
    disableLocalAuth: true
    enablePurgeProtection: true
  }
}

Configure with Bicep Public Registry#

To deploy App Configuration Stores that pass this rule:

  • Set params.name to a value that meets the requirements.

For example:

Azure Bicep snippet
module br_public_store 'br/public:app/app-configuration:1.1.2' = {
  name: 'store'
  params: {
    skuName: 'Standard'
    disableLocalAuth: true
    enablePurgeProtection: true
    publicNetworkAccess: 'Disabled'
    replicas: [
      {
        name: 'eastus'
        location: 'eastus'
      }
    ]
  }
}

Notes#

This rule does not check if App Configuration store names are unique.

Comments