我正在根据本文尝试在ARM模板中设置一些标签:https : //docs.microsoft.com/zh-cn/azure/azure-resource-manager/resource-manager-templates-resources#apply-一个对象到标签元素
我希望能够在TagValues参数中设置几个通用标记,然后为其他特定资源附加其他标记。这有可能吗?我尝试使用[concat()],但它对处理对象不满意,并且验证失败。
这是我要执行的操作的一个示例:
{
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"tagValues": {
"type": "object",
"defaultValue": {
"Dept": "Finance",
"Environment": "Production"
}
}
},
"resources": [
{
"apiVersion": "2016-01-01",
"type": "Microsoft.Storage/storageAccounts",
"name": "[concat('storage', uniqueString(resourceGroup().id))]",
"location": "[resourceGroup().location]",
"tags": "[parameters('tagValues')]", // want to concatenate another tag here, so that the following is returned: "Dept": "Finance", "Environment": "Production", "myExtraTag": "myTagValue"
"sku": {
"name": "Standard_LRS"
},
"kind": "Storage",
"properties": {}
}
{
"apiVersion": "2016-01-01",
"type": "Microsoft.Storage/storageAccounts",
"name": "mySecondResource",
"location": "[resourceGroup().location]",
"tags": "[parameters('tagValues')]", …Run Code Online (Sandbox Code Playgroud) 我正在尝试为逻辑应用程序和 Azure 函数配置安全性。Azure 函数有一个 HTTP 触发器。到目前为止,我已经完成了以下工作:
当我运行逻辑应用程序时,它显示 HTTP 操作失败,因为它未经授权。谁能告诉我我错过了什么?我找到了一些关于如何使用类似方法访问 KeyVault(例如)的教程,但对于 Azure 函数却没有。我觉得我需要告诉应用注册逻辑应用的托管标识有权限,但我不知道这是否正确,也不知道如何去做。
azure azure-active-directory azure-logic-apps azure-functions
azure ×2