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

Microsoft.Network serviceEndpoint策略 2018-10-01

Bicep 资源定义

可以使用目标操作部署 serviceEndpointPolicies 资源类型:

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

用法示例

Bicep 示例

部署子网服务端点存储策略的基本示例。

param location string = 'westeurope'
param resourceName string = 'acctest0001'

resource serviceEndpointPolicy 'Microsoft.Network/serviceEndpointPolicies@2022-07-01' = {
  name: resourceName
  location: location
  properties: {}
}

Azure 验证模块

以下 Azure 验证模块 可用于部署此资源类型。

模块 描述
服务终结点策略 服务终结点策略的 AVM 资源模块

资源格式

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

resource symbolicname 'Microsoft.Network/serviceEndpointPolicies@2018-10-01' = {
  etag: 'string'
  location: 'string'
  name: 'string'
  properties: {
    serviceEndpointPolicyDefinitions: [
      {
        etag: 'string'
        id: 'string'
        name: 'string'
        properties: {
          description: 'string'
          service: 'string'
          serviceResources: [
            'string'
          ]
        }
      }
    ]
  }
  tags: {
    {customized property}: 'string'
  }
}

属性值

Microsoft.Network/serviceEndpoint策略

名字 描述 价值
ETAG 一个唯一的只读字符串,每当更新资源时更改。 字符串
位置 资源位置。 字符串
名字 资源名称 string (必需)
性能 服务终结点策略的属性。 ServiceEndpointPolicyPropertiesFormat
标签 资源标记 标记名称和值的字典。 请参阅模板 中的 标记

资源标签

名字 描述 价值

ServiceEndpointPolicyDefinition

名字 描述 价值
ETAG 一个唯一的只读字符串,每当更新资源时更改。 字符串
id 资源 ID。 字符串
名字 资源组中唯一的资源的名称。 此名称可用于访问资源。 字符串
性能 服务终结点策略定义的属性。 ServiceEndpointPolicyDefinitionPropertiesFormat

ServiceEndpointPolicyDefinitionPropertiesFormat

名字 描述 价值
描述 此规则的说明。 限制为 140 个字符。 字符串
服务 服务终结点名称。 字符串
服务资源 服务资源列表。 字符串[]

ServiceEndpointPolicyPropertiesFormat

名字 描述 价值
serviceEndpointPolicyDefinitions 服务终结点策略的服务终结点策略定义的集合。 ServiceEndpointPolicyDefinition[]

ARM 模板资源定义

可以使用目标操作部署 serviceEndpointPolicies 资源类型:

用法示例

Azure 快速入门模板

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

模板 描述
部署 Darktrace 自动缩放 vSensors

部署到 Azure
此模板允许你部署 Darktrace vSensors 的自动自动缩放部署

资源格式

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

{
  "type": "Microsoft.Network/serviceEndpointPolicies",
  "apiVersion": "2018-10-01",
  "name": "string",
  "etag": "string",
  "location": "string",
  "properties": {
    "serviceEndpointPolicyDefinitions": [
      {
        "etag": "string",
        "id": "string",
        "name": "string",
        "properties": {
          "description": "string",
          "service": "string",
          "serviceResources": [ "string" ]
        }
      }
    ]
  },
  "tags": {
    "{customized property}": "string"
  }
}

属性值

Microsoft.Network/serviceEndpoint策略

名字 描述 价值
apiVersion API 版本 '2018-10-01'
ETAG 一个唯一的只读字符串,每当更新资源时更改。 字符串
位置 资源位置。 字符串
名字 资源名称 string (必需)
性能 服务终结点策略的属性。 ServiceEndpointPolicyPropertiesFormat
标签 资源标记 标记名称和值的字典。 请参阅模板 中的 标记
类型 资源类型 “Microsoft.Network/serviceEndpointPolicies”

资源标签

名字 描述 价值

ServiceEndpointPolicyDefinition

名字 描述 价值
ETAG 一个唯一的只读字符串,每当更新资源时更改。 字符串
id 资源 ID。 字符串
名字 资源组中唯一的资源的名称。 此名称可用于访问资源。 字符串
性能 服务终结点策略定义的属性。 ServiceEndpointPolicyDefinitionPropertiesFormat

ServiceEndpointPolicyDefinitionPropertiesFormat

名字 描述 价值
描述 此规则的说明。 限制为 140 个字符。 字符串
服务 服务终结点名称。 字符串
服务资源 服务资源列表。 字符串[]

ServiceEndpointPolicyPropertiesFormat

名字 描述 价值
serviceEndpointPolicyDefinitions 服务终结点策略的服务终结点策略定义的集合。 ServiceEndpointPolicyDefinition[]

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

可以使用目标操作部署 serviceEndpointPolicies 资源类型:

  • 资源组 关于每个API版本中变更属性的列表,请参见 更改日志。

用法示例

Terraform 示例

部署子网服务端点存储策略的基本示例。

terraform {
  required_providers {
    azapi = {
      source = "Azure/azapi"
    }
  }
}

provider "azapi" {
  skip_provider_registration = false
}

variable "resource_name" {
  type    = string
  default = "acctest0001"
}

variable "location" {
  type    = string
  default = "westeurope"
}

resource "azapi_resource" "resourceGroup" {
  type     = "Microsoft.Resources/resourceGroups@2020-06-01"
  name     = var.resource_name
  location = var.location
}

resource "azapi_resource" "serviceEndpointPolicy" {
  type      = "Microsoft.Network/serviceEndpointPolicies@2022-07-01"
  parent_id = azapi_resource.resourceGroup.id
  name      = var.resource_name
  location  = var.location
  body = {
    properties = {
    }
  }
  schema_validation_enabled = false
  response_export_values    = ["*"]
}

资源格式

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

resource "azapi_resource" "symbolicname" {
  type = "Microsoft.Network/serviceEndpointPolicies@2018-10-01"
  name = "string"
  parent_id = "string"
  location = "string"
  tags = {
    {customized property} = "string"
  }
  body = {
    etag = "string"
    properties = {
      serviceEndpointPolicyDefinitions = [
        {
          etag = "string"
          id = "string"
          name = "string"
          properties = {
            description = "string"
            service = "string"
            serviceResources = [
              "string"
            ]
          }
        }
      ]
    }
  }
}

属性值

Microsoft.Network/serviceEndpoint策略

名字 描述 价值
ETAG 一个唯一的只读字符串,每当更新资源时更改。 字符串
位置 资源位置。 字符串
名字 资源名称 string (必需)
性能 服务终结点策略的属性。 ServiceEndpointPolicyPropertiesFormat
标签 资源标记 标记名称和值的字典。
类型 资源类型 “Microsoft.Network/serviceEndpointPolicies@2018-10-01”

资源标签

名字 描述 价值

ServiceEndpointPolicyDefinition

名字 描述 价值
ETAG 一个唯一的只读字符串,每当更新资源时更改。 字符串
id 资源 ID。 字符串
名字 资源组中唯一的资源的名称。 此名称可用于访问资源。 字符串
性能 服务终结点策略定义的属性。 ServiceEndpointPolicyDefinitionPropertiesFormat

ServiceEndpointPolicyDefinitionPropertiesFormat

名字 描述 价值
描述 此规则的说明。 限制为 140 个字符。 字符串
服务 服务终结点名称。 字符串
服务资源 服务资源列表。 字符串[]

ServiceEndpointPolicyPropertiesFormat

名字 描述 价值
serviceEndpointPolicyDefinitions 服务终结点策略的服务终结点策略定义的集合。 ServiceEndpointPolicyDefinition[]