全部产品
Search
文档中心

资源编排:ALIYUN::VPC::AnycastEIPAssociation

更新时间:Jul 17, 2024

ALIYUN::VPC::AnycastEIPAssociation类型用于将任播弹性公网IP(Anycast EIP)绑定到指定地域的云资源实例上。

语法

{
  "Type": "ALIYUN::VPC::AnycastEIPAssociation",
  "Properties": {
    "BindInstanceId": String,
    "BindInstanceRegionId": String,
    "BindInstanceType": String,
    "AnycastId": String
  }
}

属性

属性名称

类型

必须

允许更新

描述

约束

BindInstanceId

String

待绑定的云资源实例ID。

BindInstanceRegionId

String

待绑定的云资源实例地域ID。

BindInstanceType

String

待绑定的云资源实例类型。

取值:SlbInstance,表示私网负载均衡(SLB)实例。

只支持绑定以下地域的SLB实例:

  • cn-hongkong:中国(香港)。

  • eu-west-1:英国(伦敦)。

  • eu-central-1:德国(法兰克福)。

  • us-east-1:美国(弗吉尼亚)。

  • us-west-1:美国(硅谷)。

  • ap-southeast-1:新加坡。

  • ap-southeast-3:马来西亚(吉隆坡)。

  • ap-northeast-1:日本(东京)。

AnycastId

String

Anycast EIP实例ID。

返回值

Fn::GetAtt

  • BindInstanceId:已绑定的云资源实例ID。

  • BindInstanceRegionId:已绑定的云资源实例地域ID。

  • BindInstanceType:已绑定的云资源实例类型。

  • AnycastId:Anycast EIP实例ID。

示例

YAML格式

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  AnycastId:
    Description: Anycast EIP instance ID.
    Type: String
  BindInstanceId:
    Description: The ID of the cloud resource instance to be bound.
    Type: String
  BindInstanceRegionId:
    Description: The region ID of the cloud resource instance to be bound.
    Type: String
  BindInstanceType:
    Description: 'The cloud resource instance type to be bound. Valid value: SlbInstance,
      SLB instance of private network type.'
    Type: String
Resources:
  AnycastEIPAssociation:
    Properties:
      AnycastId:
        Ref: AnycastId
      BindInstanceId:
        Ref: BindInstanceId
      BindInstanceRegionId:
        Ref: BindInstanceRegionId
      BindInstanceType:
        Ref: BindInstanceType
    Type: ALIYUN::VPC::AnycastEIPAssociation
Outputs:
  AnycastId:
    Description: Anycast EIP instance ID.
    Value:
      Fn::GetAtt:
      - AnycastEIPAssociation
      - AnycastId
  BindInstanceId:
    Description: The ID of the cloud resource instance to be bound.
    Value:
      Fn::GetAtt:
      - AnycastEIPAssociation
      - BindInstanceId
  BindInstanceRegionId:
    Description: The region ID of the cloud resource instance to be bound.
    Value:
      Fn::GetAtt:
      - AnycastEIPAssociation
      - BindInstanceRegionId
  BindInstanceType:
    Description: The cloud resource instance type to be bound.
    Value:
      Fn::GetAtt:
      - AnycastEIPAssociation
      - BindInstanceType

JSON格式

{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "BindInstanceId": {
      "Type": "String",
      "Description": "The ID of the cloud resource instance to be bound."
    },
    "BindInstanceRegionId": {
      "Type": "String",
      "Description": "The region ID of the cloud resource instance to be bound."
    },
    "BindInstanceType": {
      "Type": "String",
      "Description": "The cloud resource instance type to be bound. Valid value: SlbInstance, SLB instance of private network type."
    },
    "AnycastId": {
      "Type": "String",
      "Description": "Anycast EIP instance ID."
    }
  },
  "Resources": {
    "AnycastEIPAssociation": {
      "Type": "ALIYUN::VPC::AnycastEIPAssociation",
      "Properties": {
        "BindInstanceId": {
          "Ref": "BindInstanceId"
        },
        "BindInstanceRegionId": {
          "Ref": "BindInstanceRegionId"
        },
        "BindInstanceType": {
          "Ref": "BindInstanceType"
        },
        "AnycastId": {
          "Ref": "AnycastId"
        }
      }
    }
  },
  "Outputs": {
    "BindInstanceId": {
      "Description": "The ID of the cloud resource instance to be bound.",
      "Value": {
        "Fn::GetAtt": [
          "AnycastEIPAssociation",
          "BindInstanceId"
        ]
      }
    },
    "BindInstanceRegionId": {
      "Description": "The region ID of the cloud resource instance to be bound.",
      "Value": {
        "Fn::GetAtt": [
          "AnycastEIPAssociation",
          "BindInstanceRegionId"
        ]
      }
    },
    "BindInstanceType": {
      "Description": "The cloud resource instance type to be bound.",
      "Value": {
        "Fn::GetAtt": [
          "AnycastEIPAssociation",
          "BindInstanceType"
        ]
      }
    },
    "AnycastId": {
      "Description": "Anycast EIP instance ID.",
      "Value": {
        "Fn::GetAtt": [
          "AnycastEIPAssociation",
          "AnycastId"
        ]
      }
    }
  }
}