Azure / Azure/azure-quickstart-templates

Error while enabling the Object Replication in Storage account v2 via ARM template

Open
#8,775 11 comments 1 reaction 0 assignees View on GitHub
Dominant language
Bicep
Stars
14.9k
Forks
16.2k
Avg merge
6d 21h
Merged PRs (30d)
6

Description

Giving error while deploying the storage account v2 with ObjectReplicationPolicy enabled.
**Error: InvalidRequestPropertyValue: The value 'default' is not allowed for property policyId.**

Since in the documentation it is mentioned to pass 'default' in name parameter. (https://docs.microsoft.com/en-us/azure/templates/microsoft.storage/2019-06-01/storageaccounts/objectreplicationpolicies)

Here is the snippet of ARM template
{
"type": "Microsoft.Storage/storageAccounts/objectReplicationPolicies",
"apiVersion": "2019-06-01",
"name": "[concat(parameters('storageAccountName'), '/default')]",
"dependsOn": [
"[resourceId('Microsoft.Storage/storageAccounts', parameters('storageAccountName'))]",
"[resourceId('Microsoft.Storage/storageAccounts/blobServices', parameters('storageAccountName'), 'default')]"
],
"properties": {
"sourceAccount": "[parameters('storageAccountName')]",
"destinationAccount": "[parameters('destinationAccountName')]",
"rules": [
{
"sourceContainer": "[parameters('conatinerName')]",
"destinationContainer": "[parameters('destinationConatinerName')]",
"filters": {}
}
]
}
}

Contributor guide

No contributing guide indexed for this repository

Research direction

Start with the linked ARM template documentation and the shown Microsoft.Storage/storageAccounts/objectReplicationPolicies resource at apiVersion 2019-06-01. Reproduce the deployment error, then verify whether the documented name or policyId value is incorrect; done means the documentation and example agree with a successful deployment.

Written by the indexing model from the issue text.

Assessment

Tech stack
azure, json
Domain
cloud, infrastructure
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.