Todos os produtos
Search
Central de documentação

Resource Orchestration Service:ALIYUN::VPC::EIPSegment

Última atualização: Jun 27, 2026

Use o recurso ALIYUN::VPC::EIPSegment para solicitar endereços IP elásticos (EIPs) contíguos.

Sintaxe

{
  "Type": "ALIYUN::VPC::EIPSegment",
  "Properties": {
    "EipMask": Integer,
    "ResourceGroupId": String,
    "Netmode": String,
    "Bandwidth": Integer,
    "InternetChargeType": String,
    "Zone": String,
    "Isp": String
  }
}

Propriedades

Propriedade

Tipo

Obrigatório

Editável

Descrição

Restrição

EipMask

Integer

Sim

Não

Comprimento da máscara de sub-rede dos EIPs contíguos.

Valores válidos:

  • 28: aloca 16 EIPs contíguos por chamada.

  • 27: aloca 32 EIPs contíguos por chamada.

  • 26: aloca 64 EIPs contíguos por chamada.

  • 25: aloca 128 EIPs contíguos por chamada.

  • 24: aloca 256 EIPs contíguos por chamada.

Nota

A quantidade real de EIPs solicitados pode ser menor que a esperada porque o sistema reserva um, três ou quatro EIPs.

ResourceGroupId

String

Não

Não

ID do grupo de recursos.

Nenhuma.

Zone

String

Não

Não

Zona onde o sistema cria os EIPs contíguos.

Nenhuma

Isp

String

Não

Não

Tipo de linha.

Valores válidos:

  • BGP (padrão): BGP (Multi-ISP). Todas as regiões oferecem suporte a EIPs BGP (Multi-ISP).

  • BGP_PRO: BGP (Multi-ISP) Pro. Este tipo de linha está disponível apenas nas regiões China (Hong Kong), Singapura, Japão (Tóquio), Malásia (Kuala Lumpur), Filipinas (Manila), Indonésia (Jacarta) e Tailândia (Bangkok).

Para obter mais informações sobre as linhas BGP (Multi-ISP) e BGP (Multi-ISP) Pro, consulte O que é um EIP?.

Se você estiver na lista de permissões para largura de banda de ISP único, também poderá selecionar um dos seguintes valores:

  • ChinaTelecom: China Telecom

  • ChinaUnicom: China Unicom

  • ChinaMobile: China Mobile

  • ChinaTelecom_L2: China Telecom L2

  • ChinaUnicom_L2: China Unicom L2

  • ChinaMobile_L2: China Mobile L2

Para usuários do Hangzhou Finance Cloud, este parâmetro é obrigatório e deve ter o valor BGP_FinanceCloud.

Netmode

String

Não

Não

Tipo de rede dos EIPs contíguos.

Valores válidos:

  • public (padrão): Internet. Após a associação dos EIPs contíguos aos recursos de nuvem, esses recursos acessam a Internet pelos EIPs.

  • hybrid: nuvem híbrida. Após a associação dos EIPs contíguos aos recursos de nuvem, esses recursos acessam nuvens híbridas pelos EIPs.

Nota

Somente usuários incluídos na lista de permissões podem definir Netmode como hybrid. Para usar esse tipo de rede, entre em contato com seu gerente de contas.

Bandwidth

Integer

Não

Não

Largura de banda máxima do EIP.

Valor padrão: 5.

Unidade: Mbit/s.

InternetChargeType

String

Não

Não

Método de faturamento dos EIPs contíguos.

Valores válidos:

  • PayByBandwidth (padrão): pagamento por largura de banda

  • PayByTraffic: pagamento por transferência de dados

Nota

Quando Netmode está definido como hybrid, o InternetChangeType aceita apenas o valor PayByBandwidth.

Valores de retorno

Fn::GetAtt

  • EipSegmentInstanceId: ID do grupo de EIPs contíguos.

  • EipAddresses: os EIPs.

Exemplos

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  EipMask:
    Type: Number
    Description: |-
      The mask of the contiguous EIP group. Valid values:
      28: Allocates 16 contiguous EIPs.
      27: Allocates 32 contiguous EIPs.
      26: Allocates 64 contiguous EIPs.
      25: Allocates 128 contiguous EIPs.
      24: Allocates 256 contiguous EIPs.
      Note: The actual number of allocated EIPs may be fewer than expected because the system reserves one,
      three, or four IP addresses.
    AllowedValues:
      - 28
      - 27
      - 26
      - 25
      - 24
    Default: 28
  ResourceGroupId:
    Type: String
    Description: The ID of the resource group.
    Default: Null
  Netmode:
    Type: String
    Description: |-
      The network type. Valid values:
      public: (Default) Internet. Allows associated cloud resources to access the Internet.
      hybrid: Hybrid cloud. Allows associated cloud resources to communicate with the hybrid cloud.
      Note: This network type is available only to users who are on the allowlist. To use
      this network type, contact your account manager.
    AllowedValues:
      - public
      - hybrid
    Default: public
  Bandwidth:
    Type: Number
    Description: 'The peak bandwidth of the contiguous EIPs. Unit: Mbps. Default: 5.'
    Default: 5
  InternetChargeType:
    Type: String
    Description: |-
      The billing method of the contiguous EIPs. Valid values:
      PayByBandwidth: (Default) Charges are based on bandwidth.
      PayByTraffic: Charges are based on data transfer.
      Note: If Netmode is hybrid, InternetChargeType must be PayByBandwidth.
    AllowedValues:
      - PayByBandwidth
      - PayByTraffic
    Default: PayByBandwidth
Resources:
  EIPSegment:
    Type: ALIYUN::VPC::EIPSegment
    Properties:
      EipMask:
        Ref: EipMask
      ResourceGroupId:
        Ref: ResourceGroupId
      Netmode:
        Ref: Netmode
      Bandwidth:
        Ref: Bandwidth
      InternetChargeType:
        Ref: InternetChargeType
Outputs:
  EipSegmentInstanceId:
    Description: The ID of the contiguous EIP group.
    Value:
      Fn::GetAtt:
        - EIPSegment
        - EipSegmentInstanceId
  EipAddresses:
    Description: 'The list of allocated EIPs. Example: [{"AllocationId": "eip-xxx", "IpAddress": "xx.xx.xx.xx"}]'
    Value:
      Fn::GetAtt:
        - EIPSegment
        - EipAddresses
{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "EipMask": {
      "Type": "Number",
      "Description": "The mask of the contiguous EIP group. Valid values:\n28: Allocates 16 contiguous EIPs.\n27: Allocates 32 contiguous EIPs.\n26: Allocates 64 contiguous EIPs.\n25: Allocates 128 contiguous EIPs.\n24: Allocates 256 contiguous EIPs.\nNote: The actual number of allocated EIPs may be fewer than expected because the system reserves one,\nthree, or four IP addresses.",
      "AllowedValues": [
        28,
        27,
        26,
        25,
        24
      ],
      "Default": 28
    },
    "ResourceGroupId": {
      "Type": "String",
      "Description": "The ID of the resource group.",
      "Default": null
    },
    "Netmode": {
      "Type": "String",
      "Description": "The network type. Valid values:\npublic: (Default) Internet. Allows associated cloud resources to access the Internet.\nhybrid: Hybrid cloud. Allows associated cloud resources to communicate with the hybrid cloud.\nNote: This network type is available only to users who are on the allowlist. To use\nthis network type, contact your account manager.",
      "AllowedValues": [
        "public",
        "hybrid"
      ],
      "Default": "public"
    },
    "Bandwidth": {
      "Type": "Number",
      "Description": "The peak bandwidth of the contiguous EIPs. Unit: Mbps. Default: 5.",
      "Default": 5
    },
    "InternetChargeType": {
      "Type": "String",
      "Description": "The billing method of the contiguous EIPs. Valid values:\nPayByBandwidth: (Default) Charges are based on bandwidth.\nPayByTraffic: Charges are based on data transfer.\nNote: If Netmode is hybrid, InternetChargeType must be PayByBandwidth.",
      "AllowedValues": [
        "PayByBandwidth",
        "PayByTraffic"
      ],
      "Default": "PayByBandwidth"
    }
  },
  "Resources": {
    "EIPSegment": {
      "Type": "ALIYUN::VPC::EIPSegment",
      "Properties": {
        "EipMask": {
          "Ref": "EipMask"
        },
        "ResourceGroupId": {
          "Ref": "ResourceGroupId"
        },
        "Netmode": {
          "Ref": "Netmode"
        },
        "Bandwidth": {
          "Ref": "Bandwidth"
        },
        "InternetChargeType": {
          "Ref": "InternetChargeType"
        }
      }
    }
  },
  "Outputs": {
    "EipSegmentInstanceId": {
      "Description": "The ID of the contiguous EIP group.",
      "Value": {
        "Fn::GetAtt": [
          "EIPSegment",
          "EipSegmentInstanceId"
        ]
      }
    },
    "EipAddresses": {
      "Description": "The list of allocated EIPs. Example: [{\"AllocationId\": \"eip-xxx\", \"IpAddress\": \"xx.xx.xx.xx\"}]",
      "Value": {
        "Fn::GetAtt": [
          "EIPSegment",
          "EipAddresses"
        ]
      }
    }
  }
}