我正在運行二頭肌 0.4.1318。
我有一個“主”二頭肌模塊,它呼叫一個子模塊來提供資料工廠:
var adfName = 'adf-ctaxrebate-${envPlusSuffix}-${formattedInstanceNum}'
module adfDeploy 'CTaxRebate.dataFactory.bicep' = {
name: 'adfDeploy'
params: {
adfName: adfName
}
}
資料工廠模塊如下:
param adfName string
resource adf 'Microsoft.DataFactory/factories@2018-06-01' = {
name:adfName
location: resourceGroup().location
}
output dfId string = adf.identity.principalId
我使用 PowerShell cdmlet New-AzResourceGroupDeployment 運行主二頭肌,但出現以下錯誤:
模板輸出“dfId”無效:語言運算式
| 屬性“身份”不存在,可用屬性是“apiVersion、位置、標簽等...
我認為這是試圖告訴我 adf 模塊中的以下行是錯誤的:
output dfId string = adf.identity.principalId
我對此感到困惑,因為我在以前的專案中使用了相同的代碼并且它作業正常。
此外,identity 屬性確實出現在智能感知中:

uj5u.com熱心網友回復:
您需要添加
identity: {
type: 'SystemAssigned'
}
在模塊中定義你的 DataFactory 來告訴系統它應該為你生成一個系統分配的 ID。
轉載請註明出處,本文鏈接:https://www.uj5u.com/yidong/446798.html
標籤:天蓝色 天蓝色数据工厂 天蓝色资源管理器 天蓝色二头肌
