Microsoft.Resources 部署Stacks 2022-08-01-preview

Bicep 資源定義

deploymentStacks 資源類型可以使用目標作業進行部署:

如需每個 API 版本中已變更屬性的清單,請參閱 變更記錄檔。

資源格式

若要建立 Microsoft.Resources/deploymentStacks 資源,請將下列 Bicep 新增至範本。

resource symbolicname 'Microsoft.Resources/deploymentStacks@2022-08-01-preview' = {
  name: 'string'
  location: 'string'
  tags: {
    tagName1: 'tagValue1'
    tagName2: 'tagValue2'
  }
  properties: {
    actionOnUnmanage: {
      managementGroups: 'string'
      resourceGroups: 'string'
      resources: 'string'
    }
    debugSetting: {
      detailLevel: 'string'
    }
    denySettings: {
      applyToChildScopes: bool
      excludedActions: [
        'string'
      ]
      excludedPrincipals: [
        'string'
      ]
      mode: 'string'
    }
    deploymentScope: 'string'
    description: 'string'
    error: {
      error: {}
    }
    parameters: any()
    parametersLink: {
      contentVersion: 'string'
      uri: 'string'
    }
    template: any()
    templateLink: {
      contentVersion: 'string'
      id: 'string'
      queryString: 'string'
      relativePath: 'string'
      uri: 'string'
    }
  }
}

屬性值

deploymentStacks

名稱 描述
NAME 資源名稱 需要字串 ()
location 部署堆疊的位置。 建立之後便無法變更。 它必須是其中一個支援的 Azure 位置。 字串
tags 部署堆疊資源標籤。 標記名稱和值的字典。 請參閱 範本中的標籤
properties 部署堆疊屬性。 DeploymentStackProperties

DeploymentStackProperties

名稱 描述
actionOnUnmanage 定義在更新堆疊之後,不會立即管理的資源行為。 DeploymentStackPropertiesActionOnUnmanage (必要)
debugSetting 部署的偵錯設定。 DeploymentStacksDebugSetting
denySettings 定義堆疊部署的資源如何鎖定。 DenySettings (必要)
deploymentScope 應該建立初始部署的範圍。 如果未指定範圍,則會預設為部署堆疊的範圍。 有效的範圍包括:管理群組 (格式:'/providers/Microsoft.Management/managementGroups/{managementGroupId}') ,訂用帳戶 (格式:'/subscriptions/{subscriptionId}') ,資源群組 (格式:'/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}') 。 字串
description 部署堆棧描述。 字串

約束:
最大長度 = 4096
error 所有 Azure Resource Manager API 的常見錯誤回應,以傳回失敗作業的錯誤詳細數據。 (這也會遵循 OData 錯誤回應格式。) 。 ErrorResponse
參數 定義範本部署參數的名稱和值組。 直接在要求中提供參數值,而不是連結至現有的參數檔案時,請使用這個專案。 使用parametersLink屬性或parameters屬性,但不能同時使用兩者。 它可以是 JObject 或格式正確的 JSON 字串。 針對 Bicep,您可以使用 任何 () 函式。
parametersLink 參數檔案的 URI。 使用此元素連結至現有的參數檔案。 使用parametersLink屬性或parameters屬性,但不能同時使用兩者。 DeploymentStacksParametersLink
template 範本內容。 當您想要直接在要求中傳遞範本語法,而不是連結至現有的範本時,請使用這個專案。 它可以是 JObject 或格式正確的 JSON 字串。 使用templateLink屬性或範本屬性,但不能同時使用兩者。 針對 Bicep,您可以使用 任何 () 函式。
templateLink 範本的 URI。 使用templateLink屬性或範本屬性,但不能同時使用兩者。 DeploymentStacksTemplateLink

DeploymentStackPropertiesActionOnUnmanage

名稱 描述
managementGroups 指定刪除部署堆疊時,應在資源上採取的動作。 刪除會嘗試從 Azure 刪除資源。 卸離會讓資源處於目前狀態。 'delete'
'detach'
resourceGroups 指定刪除部署堆疊時,應在資源上採取的動作。 刪除會嘗試從 Azure 刪除資源。 卸離會讓資源處於目前狀態。 'delete'
'detach'
resources 指定刪除部署堆疊時,應在資源上採取的動作。 刪除會嘗試從 Azure 刪除資源。 卸離會讓資源處於目前狀態。 'delete'
'detach' (必要)

DeploymentStacksDebugSetting

名稱 描述
detailLevel 指定要記錄以進行偵錯的資訊類型。 允許的值為 none、requestContent、responseContent 或 requestContent 和 responseContent,並以逗號分隔。 預設值是 [none]。 設定此值時,請仔細考慮部署期間傳入的信息類型。 藉由記錄要求或回應的相關信息,可能會公開透過部署作業擷取的敏感數據。 字串

DenySettings

名稱 描述
applyToChildScopes DenySettings 將會套用至子範圍。 bool
excludedActions 從 denySettings 排除的角色型管理作業清單。 最多允許200個動作。 如果 denySetting 模式設定為 'denyWriteAndDelete',則下列動作會自動附加至 'excludedActions':'*/read' 和 'Microsoft.Authorization/locks/delete'。 如果 denySetting 模式設定為 'denyDelete',則下列動作會自動附加至 'excludedActions':'Microsoft.Authorization/locks/delete'。 將會移除重複的動作。 string[]
excludedPrincipals 從鎖定中排除的 AAD 主體標識符清單。 最多允許5個主體。 string[]
mode denySettings 模式。 'denyDelete'
'denyWriteAndDelete'
必要 『none』 ()

ErrorResponse

名稱 描述
error 錯誤物件。 ErrorDetail

ErrorDetail

此物件不包含部署期間要設定的任何屬性。 所有屬性都是 ReadOnly。

名稱 描述
contentVersion 如果包含,則必須符合範本中的 ContentVersion。 字串
uri 參數檔案的 URI。 需要字串 ()
名稱 描述
contentVersion 如果包含,則必須符合範本中的 ContentVersion。 字串
id 範本規格的資源識別碼。請使用id或 uri 屬性,但不能同時使用兩者。 字串
queryString 例如,要與 templateLink URI 搭配使用的 SAS 令牌) 查詢字串 (。 字串
relativePath relativePath 屬性可用來在相對於父系的位置上部署連結的範本。 如果父範本與 TemplateSpec 連結,這會參考 TemplateSpec 中的成品。 如果父系與 URI 連結,子部署將會是父系和 relativePath URI 的組合 字串
uri 要部署之範本的 URI。 請使用 uri 或 id 屬性,但不要同時使用兩者。 字串

ARM 範本資源定義

deploymentStacks 資源類型可以使用目標作業進行部署:

如需每個 API 版本中已變更屬性的清單,請參閱 變更記錄檔。

資源格式

若要建立 Microsoft.Resources/deploymentStacks 資源,請將下列 JSON 新增至範本。

{
  "type": "Microsoft.Resources/deploymentStacks",
  "apiVersion": "2022-08-01-preview",
  "name": "string",
  "location": "string",
  "tags": {
    "tagName1": "tagValue1",
    "tagName2": "tagValue2"
  },
  "properties": {
    "actionOnUnmanage": {
      "managementGroups": "string",
      "resourceGroups": "string",
      "resources": "string"
    },
    "debugSetting": {
      "detailLevel": "string"
    },
    "denySettings": {
      "applyToChildScopes": "bool",
      "excludedActions": [ "string" ],
      "excludedPrincipals": [ "string" ],
      "mode": "string"
    },
    "deploymentScope": "string",
    "description": "string",
    "error": {
      "error": {}
    },
    "parameters": {},
    "parametersLink": {
      "contentVersion": "string",
      "uri": "string"
    },
    "template": {},
    "templateLink": {
      "contentVersion": "string",
      "id": "string",
      "queryString": "string",
      "relativePath": "string",
      "uri": "string"
    }
  }
}

屬性值

deploymentStacks

名稱 描述
類型 資源類型 'Microsoft.Resources/deploymentStacks'
apiVersion 資源 API 版本 '2022-08-01-preview'
NAME 資源名稱 需要字串 ()
location 部署堆疊的位置。 建立之後便無法變更。 它必須是其中一個支援的 Azure 位置。 字串
tags 部署堆疊資源標籤。 標記名稱和值的字典。 請參閱 範本中的標籤
properties 部署堆疊屬性。 DeploymentStackProperties

DeploymentStackProperties

名稱 描述
actionOnUnmanage 定義在更新堆疊之後,不會立即管理的資源行為。 DeploymentStackPropertiesActionOnUnmanage (必要)
debugSetting 部署的偵錯設定。 DeploymentStacksDebugSetting
denySettings 定義堆疊部署的資源如何鎖定。 DenySettings (必要)
deploymentScope 應該建立初始部署的範圍。 如果未指定範圍,則會預設為部署堆疊的範圍。 有效的範圍包括:管理群組 (格式:'/providers/Microsoft.Management/managementGroups/{managementGroupId}') ,訂用帳戶 (格式:'/subscriptions/{subscriptionId}') ,資源群組 (格式:'/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}') 。 字串
description 部署堆棧描述。 字串

約束:
最大長度 = 4096
error 所有 Azure Resource Manager API 的常見錯誤回應,可傳回失敗作業的錯誤詳細數據。 (這也會遵循 OData 錯誤回應格式。) 。 ErrorResponse
參數 定義範本部署參數的名稱和值組。 直接在要求中提供參數值,而不是連結至現有的參數檔案時,請使用這個專案。 使用parametersLink屬性或parameters屬性,但不能同時使用兩者。 它可以是 JObject 或格式正確的 JSON 字串。
parametersLink 參數檔案的 URI。 使用此元素連結至現有的參數檔案。 使用parametersLink屬性或parameters屬性,但不能同時使用兩者。 DeploymentStacksParametersLink
template 範本內容。 當您想要直接在要求中傳遞範本語法,而不是連結至現有的範本時,請使用這個專案。 它可以是 JObject 或格式正確的 JSON 字串。 使用templateLink屬性或範本屬性,但不能同時使用兩者。
templateLink 範本的 URI。 使用templateLink屬性或範本屬性,但不能同時使用兩者。 DeploymentStacksTemplateLink

DeploymentStackPropertiesActionOnUnmanage

名稱 描述
managementGroups 指定刪除部署堆疊時,應在資源上採取的動作。 刪除會嘗試從 Azure 刪除資源。 卸離會讓資源處於目前狀態。 'delete'
'detach'
resourceGroups 指定刪除部署堆疊時,應在資源上採取的動作。 刪除會嘗試從 Azure 刪除資源。 卸離會讓資源處於目前狀態。 'delete'
'detach'
resources 指定刪除部署堆疊時,應在資源上採取的動作。 刪除會嘗試從 Azure 刪除資源。 卸離會讓資源處於目前狀態。 'delete'
'detach' (必要)

DeploymentStacksDebugSetting

名稱 描述
detailLevel 指定要記錄以進行偵錯的資訊類型。 允許的值為 none、requestContent、responseContent 或 requestContent 和 responseContent,並以逗號分隔。 預設值是 [none]。 設定此值時,請仔細考慮部署期間傳入的信息類型。 藉由記錄要求或回應的相關信息,可能會公開透過部署作業擷取的敏感數據。 字串

DenySettings

名稱 描述
applyToChildScopes DenySettings 將會套用至子範圍。 bool
excludedActions 從 denySettings 排除的角色型管理作業清單。 最多允許200個動作。 如果 denySetting 模式設定為 'denyWriteAndDelete',則下列動作會自動附加至 'excludedActions':'*/read' 和 'Microsoft.Authorization/locks/delete'。 如果 denySetting 模式設定為 'denyDelete',則下列動作會自動附加至 'excludedActions':'Microsoft.Authorization/locks/delete'。 將會移除重複的動作。 string[]
excludedPrincipals 從鎖定中排除的 AAD 主體標識符清單。 最多允許5個主體。 string[]
mode denySettings 模式。 'denyDelete'
'denyWriteAndDelete'
必要 『none』 ()

ErrorResponse

名稱 描述
error 錯誤物件。 ErrorDetail

ErrorDetail

此物件不包含部署期間要設定的任何屬性。 所有屬性都是 ReadOnly。

名稱 描述
contentVersion 如果包含,則必須符合範本中的 ContentVersion。 字串
uri 參數檔案的 URI。 需要字串 ()
名稱 描述
contentVersion 如果包含,則必須符合範本中的 ContentVersion。 字串
id 範本規格的資源識別碼。請使用id或 uri 屬性,但不能同時使用兩者。 字串
queryString 例如,要與 templateLink URI 搭配使用的 SAS 令牌) 查詢字串 (。 字串
relativePath relativePath 屬性可用來在相對於父系的位置上部署連結的範本。 如果父範本與 TemplateSpec 連結,這會參考 TemplateSpec 中的成品。 如果父系與 URI 連結,子部署將會是父系和 relativePath URI 的組合 字串
uri 要部署之範本的 URI。 請使用 uri 或 id 屬性,但不要同時使用兩者。 字串

Terraform (AzAPI 提供者) 資源定義

deploymentStacks 資源類型可以使用目標作業進行部署:

  • 管理群組
  • 訂用帳戶
  • 資源群組

如需每個 API 版本中已變更屬性的清單,請參閱 變更記錄檔。

資源格式

若要建立 Microsoft.Resources/deploymentStacks 資源,請將下列 Terraform 新增至範本。

resource "azapi_resource" "symbolicname" {
  type = "Microsoft.Resources/deploymentStacks@2022-08-01-preview"
  name = "string"
  location = "string"
  parent_id = "string"
  tags = {
    tagName1 = "tagValue1"
    tagName2 = "tagValue2"
  }
  body = jsonencode({
    properties = {
      actionOnUnmanage = {
        managementGroups = "string"
        resourceGroups = "string"
        resources = "string"
      }
      debugSetting = {
        detailLevel = "string"
      }
      denySettings = {
        applyToChildScopes = bool
        excludedActions = [
          "string"
        ]
        excludedPrincipals = [
          "string"
        ]
        mode = "string"
      }
      deploymentScope = "string"
      description = "string"
      error = {
        error = {}
      }
      parametersLink = {
        contentVersion = "string"
        uri = "string"
      }
      templateLink = {
        contentVersion = "string"
        id = "string"
        queryString = "string"
        relativePath = "string"
        uri = "string"
      }
    }
  })
}

屬性值

deploymentStacks

名稱 描述
類型 資源類型 “Microsoft.Resources/deploymentStacks@2022-08-01-preview”
NAME 資源名稱 需要字串 ()
location 部署堆疊的位置。 建立之後便無法變更。 它必須是其中一個支援的 Azure 位置。 字串
parent_id 若要部署至管理群組,請使用該管理群組的標識碼。 若要部署至訂用帳戶,請使用該訂用帳戶的標識碼。 若要部署至資源群組,請使用該資源群組的標識碼。 需要字串 ()
tags 部署堆疊資源標籤。 標記名稱和值的字典。
properties 部署堆疊屬性。 DeploymentStackProperties

DeploymentStackProperties

名稱 描述
actionOnUnmanage 定義在更新堆疊之後,不會立即管理的資源行為。 DeploymentStackPropertiesActionOnUnmanage (必要)
debugSetting 部署的偵錯設定。 DeploymentStacksDebugSetting
denySettings 定義堆疊部署的資源如何鎖定。 DenySettings (必要)
deploymentScope 應該建立初始部署的範圍。 如果未指定範圍,則會預設為部署堆疊的範圍。 有效的範圍包括:管理群組 (格式:'/providers/Microsoft.Management/managementGroups/{managementGroupId}') ,訂用帳戶 (格式:'/subscriptions/{subscriptionId}') ,資源群組 (格式:'/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}') 。 字串
description 部署堆棧描述。 字串

約束:
最大長度 = 4096
error 所有 Azure Resource Manager API 的常見錯誤回應,可傳回失敗作業的錯誤詳細數據。 (這也會遵循 OData 錯誤回應格式。) 。 ErrorResponse
參數 定義範本部署參數的名稱和值組。 直接在要求中提供參數值,而不是連結至現有的參數檔案時,請使用這個專案。 使用parametersLink屬性或parameters屬性,但不能同時使用兩者。 它可以是 JObject 或格式正確的 JSON 字串。
parametersLink 參數檔案的 URI。 使用此元素連結至現有的參數檔案。 使用parametersLink屬性或parameters屬性,但不能同時使用兩者。 DeploymentStacksParametersLink
template 範本內容。 當您想要直接在要求中傳遞範本語法,而不是連結至現有的範本時,請使用這個專案。 它可以是 JObject 或格式正確的 JSON 字串。 使用templateLink屬性或範本屬性,但不能同時使用兩者。
templateLink 範本的 URI。 使用templateLink屬性或範本屬性,但不能同時使用兩者。 DeploymentStacksTemplateLink

DeploymentStackPropertiesActionOnUnmanage

名稱 描述
managementGroups 指定刪除部署堆疊時,應在資源上採取的動作。 刪除會嘗試從 Azure 刪除資源。 卸離會讓資源處於目前狀態。 “delete”
“detach”
resourceGroups 指定刪除部署堆疊時,應在資源上採取的動作。 刪除會嘗試從 Azure 刪除資源。 卸離會讓資源處於目前狀態。 “delete”
“detach”
resources 指定刪除部署堆疊時,應在資源上採取的動作。 刪除會嘗試從 Azure 刪除資源。 卸離會讓資源處於目前狀態。 “delete”
“detach” (必要)

DeploymentStacksDebugSetting

名稱 描述
detailLevel 指定要記錄以進行偵錯的資訊類型。 允許的值為 none、requestContent、responseContent 或 requestContent 和 responseContent,並以逗號分隔。 預設值是 [none]。 設定此值時,請仔細考慮部署期間傳入的信息類型。 藉由記錄要求或回應的相關信息,可能會公開透過部署作業擷取的敏感數據。 字串

DenySettings

名稱 描述
applyToChildScopes DenySettings 將會套用至子範圍。 bool
excludedActions 從 denySettings 排除的角色型管理作業清單。 最多允許200個動作。 如果 denySetting 模式設定為 'denyWriteAndDelete',則下列動作會自動附加至 'excludedActions':'*/read' 和 'Microsoft.Authorization/locks/delete'。 如果 denySetting 模式設定為 'denyDelete',則下列動作會自動附加至 'excludedActions':'Microsoft.Authorization/locks/delete'。 將會移除重複的動作。 string[]
excludedPrincipals 從鎖定中排除的 AAD 主體標識符清單。 最多允許5個主體。 string[]
mode denySettings 模式。 “denyDelete”
“denyWriteAndDelete”
“none” (必要)

ErrorResponse

名稱 描述
error error 物件。 ErrorDetail

ErrorDetail

此物件不包含部署期間要設定的任何屬性。 所有屬性都是 ReadOnly。

名稱 描述
contentVersion 如果包含,則必須符合範本中的 ContentVersion。 字串
uri 參數檔案的 URI。 字串 (必要)
名稱 描述
contentVersion 如果包含,則必須符合範本中的 ContentVersion。 字串
id 範本規格的資源識別碼。請使用id或 uri 屬性,但不能同時使用兩者。 字串
queryString 例如,查詢字串 (,要與 templateLink URI 搭配使用的 SAS 令牌) 。 字串
relativePath relativePath 屬性可用來在相對於父系的位置部署連結的範本。 如果父範本與 TemplateSpec 連結,這會參考 TemplateSpec 中的成品。 如果父系與 URI 連結,子部署將會是父系和 relativePath URI 的組合 字串
uri 要部署之範本的 URI。 使用 uri 或 id 屬性,但不能同時使用兩者。 字串