你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn

Microsoft.AppPlatform Spring/apps 2022-11-01-preview

Bicep 资源定义

Spring/apps 资源类型可以通过针对以下操作进行部署:

有关每个 API 版本中更改的属性的列表,请参阅 更改日志

资源格式

若要创建 Microsoft.AppPlatform/Spring/apps 资源,请将以下 Bicep 添加到模板。

resource symbolicname 'Microsoft.AppPlatform/Spring/apps@2022-11-01-preview' = {
  name: 'string'
  location: 'string'
  parent: resourceSymbolicName
  identity: {
    principalId: 'string'
    tenantId: 'string'
    type: 'string'
    userAssignedIdentities: {}
  }
  properties: {
    addonConfigs: {}
    customPersistentDisks: [
      {
        customPersistentDiskProperties: {
          mountOptions: [
            'string'
          ]
          mountPath: 'string'
          readOnly: bool
          type: 'string'
          // For remaining properties, see CustomPersistentDiskProperties objects
        }
        storageId: 'string'
      }
    ]
    enableEndToEndTLS: bool
    httpsOnly: bool
    ingressSettings: {
      backendProtocol: 'string'
      clientAuth: {
        certificates: [
          'string'
        ]
      }
      readTimeoutInSeconds: int
      sendTimeoutInSeconds: int
      sessionAffinity: 'string'
      sessionCookieMaxAge: int
    }
    loadedCertificates: [
      {
        loadTrustStore: bool
        resourceId: 'string'
      }
    ]
    persistentDisk: {
      mountPath: 'string'
      sizeInGB: int
    }
    public: bool
    temporaryDisk: {
      mountPath: 'string'
      sizeInGB: int
    }
    vnetAddons: {
      publicEndpoint: bool
    }
  }
}

CustomPersistentDiskProperties 对象

设置 type 属性以指定对象的类型。

对于 AzureFileVolume,请使用:

  type: 'AzureFileVolume'
  shareName: 'string'

属性值

Spring/apps

名称 说明
name 资源名称

了解如何在 Bicep 中为子资源设置名称和类型。
字符串 (必需)
location 应用程序的地理位置,始终与其父资源相同 字符串
父级 (parent) 在 Bicep 中,可以为子资源指定父资源。 仅当子资源在父资源外部声明时,才需要添加此属性。

有关详细信息,请参阅 父资源之外的子资源
类型为资源的符号名称: Spring
标识 应用资源的托管标识类型 ManagedIdentityProperties
properties 应用资源的属性 AppResourceProperties

ManagedIdentityProperties

名称 说明
principalId 系统分配的托管标识的主体 ID。 字符串
tenantId 系统分配的托管标识的租户 ID。 字符串
type 托管标识的类型 “None”
“SystemAssigned”
“SystemAssigned,UserAssigned”
“UserAssigned”
userAssignedIdentities 用户分配的托管标识的属性 对象 (object)

AppResourceProperties

名称 说明
addonConfigs 加载项集合 对象 (object)
customPersistentDisks 自定义永久性磁盘列表 CustomPersistentDiskResource[]
enableEndToEndTLS 指示是否启用了端到端 TLS。 bool
httpsOnly 指示是否仅允许 https。 bool
ingressSettings 应用入口设置有效负载。 IngressSettings
loadedCertificates 已加载证书的集合 LoadedCertificate[]
persistentDisk 永久性磁盘设置 PersistentDisk
public 指示应用是否公开公共终结点 bool
temporaryDisk 临时磁盘设置 TemporaryDisk
vnetAddons vnet 注入实例中的其他应用设置 AppVNetAddons

CustomPersistentDiskResource

名称 说明
customPersistentDiskProperties 自定义永久性磁盘资源有效负载的属性。 CustomPersistentDiskProperties
storageId Azure Spring Apps 存储资源的资源 ID。 字符串 (必需)

CustomPersistentDiskProperties

名称 说明
mountOptions 这些是永久性磁盘的装载选项。 string[]
mountPath 永久性磁盘的装载路径。 字符串 (必需)
readOnly 指示永久性磁盘是否为 readOnly 磁盘。 bool
类型 设置对象类型 AzureFileVolume (必需)

AzureFileVolume

名称 说明 Value
type 要装载为永久性磁盘的基础资源的类型。 “AzureFileVolume” (所需的)
shareName Azure 文件共享的共享名称。 字符串 (必需)

IngressSettings

名称 说明
backendProtocol 入口应如何与此应用后端服务通信。 'Default'
“GRPC”
clientAuth Client-Certification 身份验证。 IngressSettingsClientAuth
readTimeoutInSeconds 入口读取超时(以秒为单位)。 int
sendTimeoutInSeconds 入口发送超时(以秒为单位)。 int
sessionAffinity 相关性的类型,将此设置为 Cookie 以启用会话关联。 “Cookie”
“None”
sessionCookieMaxAge Cookie 过期前的时间(以秒为单位)。 int

IngressSettingsClientAuth

名称 说明
certificates 证书资源 ID 的集合。 string[]

LoadedCertificate

名称 说明
loadTrustStore 指示证书是否将加载到默认信任存储中,仅适用于 Java 运行时。 bool
ResourceId 已加载证书的资源 ID 字符串 (必需)

PersistentDisk

名称 说明
mountPath 永久性磁盘的装载路径 string
sizeInGB 永久性磁盘的大小(以 GB 为单位) int

TemporaryDisk

名称 说明
mountPath 临时磁盘的装载路径 string
sizeInGB 临时磁盘的大小(以 GB 为单位) int

AppVNetAddons

名称 说明
publicEndpoint 指示 vnet 注入实例中的应用是否公开可从 Internet 访问的终结点。 bool

快速入门模板

以下快速入门模板部署此资源类型。

模板 说明
部署简单的 Azure Spring Apps 微服务应用程序

部署到 Azure
此模板部署一个简单的 Azure Spring Apps 微服务应用程序,以在 Azure 上运行。

ARM 模板资源定义

Spring/apps 资源类型可以通过针对以下操作进行部署:

有关每个 API 版本中更改的属性的列表,请参阅 更改日志

资源格式

若要创建 Microsoft.AppPlatform/Spring/apps 资源,请将以下 JSON 添加到模板。

{
  "type": "Microsoft.AppPlatform/Spring/apps",
  "apiVersion": "2022-11-01-preview",
  "name": "string",
  "location": "string",
  "identity": {
    "principalId": "string",
    "tenantId": "string",
    "type": "string",
    "userAssignedIdentities": {}
  },
  "properties": {
    "addonConfigs": {},
    "customPersistentDisks": [
      {
        "customPersistentDiskProperties": {
          "mountOptions": [ "string" ],
          "mountPath": "string",
          "readOnly": "bool",
          "type": "string"
          // For remaining properties, see CustomPersistentDiskProperties objects
        },
        "storageId": "string"
      }
    ],
    "enableEndToEndTLS": "bool",
    "httpsOnly": "bool",
    "ingressSettings": {
      "backendProtocol": "string",
      "clientAuth": {
        "certificates": [ "string" ]
      },
      "readTimeoutInSeconds": "int",
      "sendTimeoutInSeconds": "int",
      "sessionAffinity": "string",
      "sessionCookieMaxAge": "int"
    },
    "loadedCertificates": [
      {
        "loadTrustStore": "bool",
        "resourceId": "string"
      }
    ],
    "persistentDisk": {
      "mountPath": "string",
      "sizeInGB": "int"
    },
    "public": "bool",
    "temporaryDisk": {
      "mountPath": "string",
      "sizeInGB": "int"
    },
    "vnetAddons": {
      "publicEndpoint": "bool"
    }
  }
}

CustomPersistentDiskProperties 对象

设置 type 属性以指定对象的类型。

对于 AzureFileVolume,请使用:

  "type": "AzureFileVolume",
  "shareName": "string"

属性值

Spring/apps

名称 说明 Value
type 资源类型 “Microsoft.AppPlatform/Spring/apps”
apiVersion 资源 API 版本 “2022-11-01-preview”
name 资源名称

了解如何在 JSON ARM 模板中为子资源设置名称和类型。
字符串 (必需)
location 应用程序的地理位置,始终与其父资源相同 string
标识 应用资源的托管标识类型 ManagedIdentityProperties
properties 应用资源的属性 AppResourceProperties

ManagedIdentityProperties

名称 说明
principalId 系统分配的托管标识的主体 ID。 字符串
tenantId 系统分配的托管标识的租户 ID。 字符串
type 托管标识的类型 “None”
“SystemAssigned”
“SystemAssigned,UserAssigned”
“UserAssigned”
userAssignedIdentities 用户分配的托管标识的属性 对象 (object)

AppResourceProperties

名称 说明
addonConfigs 加载项集合 对象 (object)
customPersistentDisks 自定义永久性磁盘列表 CustomPersistentDiskResource[]
enableEndToEndTLS 指示是否启用了端到端 TLS。 bool
httpsOnly 指示是否仅允许 https。 bool
ingressSettings 应用入口设置有效负载。 IngressSettings
loadedCertificates 已加载证书的集合 LoadedCertificate[]
persistentDisk 永久性磁盘设置 PersistentDisk
public 指示应用是否公开公共终结点 bool
temporaryDisk 临时磁盘设置 TemporaryDisk
vnetAddons vnet 注入实例中的其他应用设置 AppVNetAddons

CustomPersistentDiskResource

名称 说明
customPersistentDiskProperties 自定义永久性磁盘资源有效负载的属性。 CustomPersistentDiskProperties
storageId Azure Spring Apps 存储资源的资源 ID。 字符串 (必需)

CustomPersistentDiskProperties

名称 说明
mountOptions 这些是永久性磁盘的装载选项。 string[]
mountPath 永久性磁盘的装载路径。 字符串 (必需)
readOnly 指示永久性磁盘是否为 readOnly 磁盘。 bool
类型 设置对象类型 AzureFileVolume (必需)

AzureFileVolume

名称 说明 Value
type 要装载为永久性磁盘的基础资源的类型。 “AzureFileVolume” (所需的)
shareName Azure 文件共享的共享名称。 字符串 (必需)

IngressSettings

名称 说明
backendProtocol 入口应如何与此应用后端服务通信。 'Default'
“GRPC”
clientAuth Client-Certification 身份验证。 IngressSettingsClientAuth
readTimeoutInSeconds 入口读取超时(以秒为单位)。 int
sendTimeoutInSeconds 入口发送超时(以秒为单位)。 int
sessionAffinity 相关性的类型,将此设置为 Cookie 以启用会话关联。 “Cookie”
“None”
sessionCookieMaxAge Cookie 过期前的时间(以秒为单位)。 int

IngressSettingsClientAuth

名称 说明
certificates 证书资源 ID 的集合。 string[]

LoadedCertificate

名称 说明
loadTrustStore 指示证书是否将加载到默认信任存储中,仅适用于 Java 运行时。 bool
ResourceId 已加载证书的资源 ID 字符串 (必需)

PersistentDisk

名称 说明
mountPath 永久性磁盘的装载路径 字符串
sizeInGB 永久性磁盘的大小(以 GB 为单位) int

TemporaryDisk

名称 说明
mountPath 临时磁盘的装载路径 字符串
sizeInGB 临时磁盘的大小(以 GB 为单位) int

AppVNetAddons

名称 说明
publicEndpoint 指示 vnet 注入实例中的应用是否公开可从 Internet 访问的终结点。 bool

快速入门模板

以下快速入门模板部署此资源类型。

模板 说明
部署简单的 Azure Spring Apps 微服务应用程序

部署到 Azure
此模板部署一个简单的 Azure Spring Apps 微服务应用程序,以在 Azure 上运行。

Terraform (AzAPI 提供程序) 资源定义

Spring/apps 资源类型可以通过针对以下操作进行部署:

  • 资源组

有关每个 API 版本中更改的属性的列表,请参阅 更改日志

资源格式

若要创建 Microsoft.AppPlatform/Spring/apps 资源,请将以下 Terraform 添加到模板。

resource "azapi_resource" "symbolicname" {
  type = "Microsoft.AppPlatform/Spring/apps@2022-11-01-preview"
  name = "string"
  location = "string"
  parent_id = "string"
  identity {
    type = "string"
    identity_ids = []
  }
  body = jsonencode({
    properties = {
      addonConfigs = {}
      customPersistentDisks = [
        {
          customPersistentDiskProperties = {
            mountOptions = [
              "string"
            ]
            mountPath = "string"
            readOnly = bool
            type = "string"
            // For remaining properties, see CustomPersistentDiskProperties objects
          }
          storageId = "string"
        }
      ]
      enableEndToEndTLS = bool
      httpsOnly = bool
      ingressSettings = {
        backendProtocol = "string"
        clientAuth = {
          certificates = [
            "string"
          ]
        }
        readTimeoutInSeconds = int
        sendTimeoutInSeconds = int
        sessionAffinity = "string"
        sessionCookieMaxAge = int
      }
      loadedCertificates = [
        {
          loadTrustStore = bool
          resourceId = "string"
        }
      ]
      persistentDisk = {
        mountPath = "string"
        sizeInGB = int
      }
      public = bool
      temporaryDisk = {
        mountPath = "string"
        sizeInGB = int
      }
      vnetAddons = {
        publicEndpoint = bool
      }
    }
  })
}

CustomPersistentDiskProperties 对象

设置 type 属性以指定对象的类型。

对于 AzureFileVolume,请使用:

  type = "AzureFileVolume"
  shareName = "string"

属性值

Spring/apps

名称 说明 Value
type 资源类型 “Microsoft.AppPlatform/Spring/apps@2022-11-01-preview”
name 资源名称 字符串 (必需)
location 应用程序的地理位置,始终与其父资源相同 字符串
parent_id 此资源的父资源 ID。 类型为:Spring 的资源的 ID
标识 应用资源的托管标识类型 ManagedIdentityProperties
properties 应用资源的属性 AppResourceProperties

ManagedIdentityProperties

名称 说明 Value
type 托管标识的类型 “SystemAssigned”
“SystemAssigned,UserAssigned”
“UserAssigned”
identity_ids 用户分配的托管标识的属性 用户标识 ID 数组。

AppResourceProperties

名称 说明
addonConfigs 加载项集合 对象 (object)
customPersistentDisks 自定义永久性磁盘列表 CustomPersistentDiskResource[]
enableEndToEndTLS 指示是否启用了端到端 TLS。 bool
httpsOnly 指示是否仅允许 https。 bool
ingressSettings 应用入口设置有效负载。 IngressSettings
loadedCertificates 已加载证书的集合 LoadedCertificate[]
persistentDisk 永久性磁盘设置 PersistentDisk
public 指示应用是否公开公共终结点 bool
temporaryDisk 临时磁盘设置 TemporaryDisk
vnetAddons vnet 注入实例中的其他应用设置 AppVNetAddons

CustomPersistentDiskResource

名称 说明
customPersistentDiskProperties 自定义永久性磁盘资源有效负载的属性。 CustomPersistentDiskProperties
storageId Azure Spring Apps 存储资源的资源 ID。 字符串 (必需)

CustomPersistentDiskProperties

名称 说明
mountOptions 这些是永久性磁盘的装载选项。 string[]
mountPath 永久性磁盘的装载路径。 字符串 (必需)
readOnly 指示永久性磁盘是否为 readOnly 磁盘。 bool
类型 设置对象类型 AzureFileVolume (必需)

AzureFileVolume

名称 说明 Value
type 要装载为永久性磁盘的基础资源的类型。 “AzureFileVolume” (必需)
shareName Azure 文件共享的共享名称。 字符串 (必需)

IngressSettings

名称 说明
backendProtocol 入口应如何与此应用后端服务通信。 “Default”
“GRPC”
clientAuth Client-Certification 身份验证。 IngressSettingsClientAuth
readTimeoutInSeconds 入口读取超时(以秒为单位)。 int
sendTimeoutInSeconds 入口发送超时(以秒为单位)。 int
sessionAffinity 相关性的类型,将此设置为 Cookie 以启用会话相关性。 “Cookie”
"None"
sessionCookieMaxAge Cookie 过期前的时间(以秒为单位)。 int

IngressSettingsClientAuth

名称 说明
certificates 证书资源 ID 的集合。 string[]

LoadedCertificate

名称 说明
loadTrustStore 指示证书是否将加载到默认信任存储中,仅适用于 Java 运行时。 bool
ResourceId 已加载证书的资源 ID 字符串 (必需)

PersistentDisk

名称 说明
mountPath 永久性磁盘的装载路径 string
sizeInGB 永久性磁盘的大小(以 GB 为单位) int

TemporaryDisk

名称 说明
mountPath 临时磁盘的装载路径 string
sizeInGB 临时磁盘的大小(以 GB 为单位) int

AppVNetAddons

名称 说明
publicEndpoint 指示 vnet 注入实例中的应用是否公开可从 Internet 访问的终结点。 bool