共用方式為


Microsoft.AppPlatform Spring/apps/deployments 2020-11-01-preview

Bicep 資源定義

Spring/apps/deployments 資源類型可以使用目標作業來部署:

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

資源格式

若要建立 Microsoft.AppPlatform/Spring/apps/deployments 資源,請將下列 Bicep 新增至範本。

resource symbolicname 'Microsoft.AppPlatform/Spring/apps/deployments@2020-11-01-preview' = {
  parent: resourceSymbolicName
  name: 'string'
  properties: {
    deploymentSettings: {
      cpu: int
      environmentVariables: {
        {customized property}: 'string'
      }
      jvmOptions: 'string'
      memoryInGB: int
      netCoreMainEntryPath: 'string'
      runtimeVersion: 'string'
    }
    source: {
      artifactSelector: 'string'
      relativePath: 'string'
      type: 'string'
      version: 'string'
    }
  }
  sku: {
    capacity: int
    name: 'string'
    tier: 'string'
  }
}

屬性值

DeploymentResourceProperties

名字 描述 價值
deploymentSettings 部署的部署設定 DeploymentSettings
已上傳部署的來源資訊。 UserSourceInfo

DeploymentSettings

名字 描述 價值
中央處理器 必要 CPU,基本層應為 1,標準層應位於範圍 (1, 4) int
environmentVariables 環境變數的集合 DeploymentSettingsEnvironmentVariables
jvmOptions JVM 參數 字串
memoryInGB GB 所需的記憶體大小,基本層應位於範圍 (1, 2), 標準層應位於範圍 (1, 8) int
netCoreMainEntryPath 相對於 zip 根目錄的 .NET 可執行文件路徑 字串
runtimeVersion 運行時間版本 'Java_11'
'Java_8'
'NetCore_31'

DeploymentSettingsEnvironmentVariables

名字 描述 價值

Microsoft.AppPlatform/Spring/apps/deployments

名字 描述 價值
名字 資源名稱 字串 (必要)
父母 在 Bicep 中,您可以指定子資源的父資源。 只有在父資源外部宣告子資源時,才需要新增這個屬性。

如需詳細資訊,請參閱 父資源外部的子資源
類型的資源符號名稱:Spring/apps
性能 部署資源的屬性 DeploymentResourceProperties
sku 部署資源的 SKU Sku

Sku

名字 描述 價值
能力 目標資源的目前容量 int
名字 Sku 的名稱 字串
Sku 的階層 字串

UserSourceInfo

名字 描述 價值
artifactSelector 要用於多模組專案的部署成品選取器。 這應該是
目標模組/項目的相對路徑。
字串
relativePath 儲存來源之記憶體的相對路徑 字串
類型 上傳的來源類型 'Jar'
'NetCoreZip'
'Source'
版本 來源的版本 字串

使用範例

Azure 快速入門範例

下列 Azure 快速入門範本 包含用於部署此資源類型的 Bicep 範例。

Bicep 檔案 描述
部署簡單的 Azure Spring Apps 微服務應用程式 此範本會部署簡單的 Azure Spring Apps 微服務應用程式,以在 Azure 上執行。

ARM 樣本資源定義

Spring/apps/deployments 資源類型可以使用目標作業來部署:

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

資源格式

若要建立 Microsoft.AppPlatform/Spring/apps/deployments 資源,請將下列 JSON 新增至範本。

{
  "type": "Microsoft.AppPlatform/Spring/apps/deployments",
  "apiVersion": "2020-11-01-preview",
  "name": "string",
  "properties": {
    "deploymentSettings": {
      "cpu": "int",
      "environmentVariables": {
        "{customized property}": "string"
      },
      "jvmOptions": "string",
      "memoryInGB": "int",
      "netCoreMainEntryPath": "string",
      "runtimeVersion": "string"
    },
    "source": {
      "artifactSelector": "string",
      "relativePath": "string",
      "type": "string",
      "version": "string"
    }
  },
  "sku": {
    "capacity": "int",
    "name": "string",
    "tier": "string"
  }
}

屬性值

DeploymentResourceProperties

名字 描述 價值
deploymentSettings 部署的部署設定 DeploymentSettings
已上傳部署的來源資訊。 UserSourceInfo

DeploymentSettings

名字 描述 價值
中央處理器 必要 CPU,基本層應為 1,標準層應位於範圍 (1, 4) int
environmentVariables 環境變數的集合 DeploymentSettingsEnvironmentVariables
jvmOptions JVM 參數 字串
memoryInGB GB 所需的記憶體大小,基本層應位於範圍 (1, 2), 標準層應位於範圍 (1, 8) int
netCoreMainEntryPath 相對於 zip 根目錄的 .NET 可執行文件路徑 字串
runtimeVersion 運行時間版本 'Java_11'
'Java_8'
'NetCore_31'

DeploymentSettingsEnvironmentVariables

名字 描述 價值

Microsoft.AppPlatform/Spring/apps/deployments

名字 描述 價值
apiVersion API 版本 '2020-11-01-preview'
名字 資源名稱 字串 (必要)
性能 部署資源的屬性 DeploymentResourceProperties
sku 部署資源的 SKU Sku
類型 資源類型 'Microsoft.AppPlatform/Spring/apps/deployments'

Sku

名字 描述 價值
能力 目標資源的目前容量 int
名字 Sku 的名稱 字串
Sku 的階層 字串

UserSourceInfo

名字 描述 價值
artifactSelector 要用於多模組專案的部署成品選取器。 這應該是
目標模組/項目的相對路徑。
字串
relativePath 儲存來源之記憶體的相對路徑 字串
類型 上傳的來源類型 'Jar'
'NetCoreZip'
'Source'
版本 來源的版本 字串

使用範例

Azure 快速入門範本

下列 Azure 快速入門範本 部署此資源類型。

範本 描述
部署簡單的 Azure Spring Apps 微服務應用程式

部署至 Azure
此範本會部署簡單的 Azure Spring Apps 微服務應用程式,以在 Azure 上執行。

Terraform (AzAPI 提供者) 資源定義

Spring/apps/deployments 資源類型可以使用目標作業來部署:

  • 資源群組

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

資源格式

若要建立 Microsoft.AppPlatform/Spring/apps/deployments 資源,請將下列 Terraform 新增至範本。

resource "azapi_resource" "symbolicname" {
  type = "Microsoft.AppPlatform/Spring/apps/deployments@2020-11-01-preview"
  name = "string"
  sku = {
    capacity = int
    name = "string"
    tier = "string"
  }
  body = jsonencode({
    properties = {
      deploymentSettings = {
        cpu = int
        environmentVariables = {
          {customized property} = "string"
        }
        jvmOptions = "string"
        memoryInGB = int
        netCoreMainEntryPath = "string"
        runtimeVersion = "string"
      }
      source = {
        artifactSelector = "string"
        relativePath = "string"
        type = "string"
        version = "string"
      }
    }
  })
}

屬性值

DeploymentResourceProperties

名字 描述 價值
deploymentSettings 部署的部署設定 DeploymentSettings
已上傳部署的來源資訊。 UserSourceInfo

DeploymentSettings

名字 描述 價值
中央處理器 必要 CPU,基本層應為 1,標準層應位於範圍 (1, 4) int
environmentVariables 環境變數的集合 DeploymentSettingsEnvironmentVariables
jvmOptions JVM 參數 字串
memoryInGB GB 所需的記憶體大小,基本層應位於範圍 (1, 2), 標準層應位於範圍 (1, 8) int
netCoreMainEntryPath 相對於 zip 根目錄的 .NET 可執行文件路徑 字串
runtimeVersion 運行時間版本 'Java_11'
'Java_8'
'NetCore_31'

DeploymentSettingsEnvironmentVariables

名字 描述 價值

Microsoft.AppPlatform/Spring/apps/deployments

名字 描述 價值
名字 資源名稱 字串 (必要)
parent_id 此資源為父系之資源的標識碼。 類型資源的標識碼:Spring/apps
性能 部署資源的屬性 DeploymentResourceProperties
sku 部署資源的 SKU Sku
類型 資源類型 “Microsoft.AppPlatform/Spring/apps/deployments@2020-11-01-preview”

Sku

名字 描述 價值
能力 目標資源的目前容量 int
名字 Sku 的名稱 字串
Sku 的階層 字串

UserSourceInfo

名字 描述 價值
artifactSelector 要用於多模組專案的部署成品選取器。 這應該是
目標模組/項目的相對路徑。
字串
relativePath 儲存來源之記憶體的相對路徑 字串
類型 上傳的來源類型 'Jar'
'NetCoreZip'
'Source'
版本 來源的版本 字串