Todos os produtos
Search
Central de documentação

Resource Orchestration Service:ALIYUN::OTS::VpcBinder

Última atualização: Jun 27, 2026

O recurso ALIYUN::OTS::VpcBinder vincula uma instância do Tablestore a uma Virtual Private Cloud (VPC).

Sintaxe

{
  "Type": "ALIYUN::OTS::VpcBinder",
  "Properties": {
    "Vpcs": List,
    "InstanceName": String
  }
}            

Propriedades

Propriedade

Tipo

Obrigatória

Editável

Descrição

Restrição

Vpcs

List

Sim

Sim

Configurações de vinculação da VPC.

O tipo de elemento desta propriedade é VpcInfo.

InstanceName

String

Sim

Não

Nome da instância do Tablestore.

Nenhuma.

Sintaxe de Vpcs

"Vpcs":[
  {
    "VpcId":String,
    "InstanceVpcName":String,
    "VirtualSwitchId": String,
    "Network": String
  }
]           

Propriedades de Vpcs

Propriedade

Tipo

Obrigatória

Editável

Descrição

Restrição

VpcId

String

Sim

Não

ID da VPC.

A VPC e a instância do Tablestore devem pertencer à mesma conta e estar na mesma região.

InstanceVpcName

String

Sim

Não

Nome personalizado.

O nome deve ser único na instância do Tablestore.

VirtualSwitchId

String

Sim

Não

ID do vSwitch.

O vSwitch deve pertencer à VPC especificada.

Network

String

Sim

Não

Tipo de rede da instância do Tablestore.

Valores válidos:

  • NORMAL (padrão): a instância do Tablestore aceita solicitações de todas as origens.

  • VPC: a instância do Tablestore aceita solicitações apenas das VPCs às quais está vinculada.

  • VPC_CONSOLE: a instância do Tablestore aceita solicitações apenas do console do Tablestore e das VPCs às quais está vinculada.

Valores de retorno

Fn::GetAtt

  • Domains: nomes de domínio para acesso à instância do Tablestore na VPC.

  • Endpoints: endpoints privados para acesso à instância do Tablestore na VPC.

Exemplos

YAML formato

ROSTemplateFormatVersion: '2015-09-01'
Description: Test Tablestore, a Tablestore instance, and VPC binding
Parameters:
  InstanceName:
    Type: String
    Description: OTS Instance name
    Default: mytest
  InstanceVpcName:
    Type: String
    Description: Instance name
    Default: mytest
  VSwitchZoneId:
    Type: String
    AssociationProperty: ALIYUN::ECS::Instance::ZoneId
    Description: Availability ID for existing switches
    Label: VSwitch Zone ID
  VpcId:
    Type: String
    Default: Null
    AssociationProperty: ALIYUN::ECS::VPC::VPCId
    Description: Please search the ID starts with (vpc-xxx)from console-Virtual Private Cloud
    Label: Existing VPC ID
  VSwitchId:
    Type: String
    Default: Null
    AssociationProperty: ALIYUN::ECS::VSwitch::VSwitchId
    Description: Please search the business VSwitch ID starts with(vsw-xxx)from console-Virtual Private Cloud-VSwitches
    Label: VSwitch ID
    AssociationPropertyMetadata:
      ZoneId: ${VSwitchZoneId}
      VpcId: ${VpcId}
Resources:
  VpcBinder:
    Type: ALIYUN::OTS::VpcBinder
    Properties:
      InstanceName:
        Ref: InstanceName
      Vpcs:
        - VpcId:
            Ref: VpcId
          InstanceVpcName:
            Ref: InstanceVpcName
          VirtualSwitchId:
            Ref: VSwitchZoneId
          Network: NORMAL
Outputs:
  Domains:
    Value:
      Fn::GetAtt:
        - VpcBinder
        - Domains
  Endpoints:
    Value:
      Fn::GetAtt:
        - VpcBinder
        - Endpoints

JSON formato

{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Description": "Test Tablestore, a Tablestore instance, and VPC binding",
  "Parameters": {
    "InstanceName": {
      "Type": "String",
      "Description": "OTS Instance name",
      "Default": "mytest"
    },
    "InstanceVpcName": {
      "Type": "String",
      "Description": "Instance name",
      "Default": "mytest"
    },
    "VSwitchZoneId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::ECS::Instance::ZoneId",
      "Description": "Availability ID for existing switches",
      "Label": "VSwitch Zone ID"
    },
    "VpcId": {
      "Type": "String",
      "Default": null,
      "AssociationProperty": "ALIYUN::ECS::VPC::VPCId",
      "Description": "Please search the ID starts with (vpc-xxx)from console-Virtual Private Cloud",
      "Label": "Existing VPC ID"
    },
    "VSwitchId": {
      "Type": "String",
      "Default": null,
      "AssociationProperty": "ALIYUN::ECS::VSwitch::VSwitchId",
      "Description": "Please search the business VSwitch ID starts with(vsw-xxx)from console-Virtual Private Cloud-VSwitches",
      "Label": "VSwitch ID",
      "AssociationPropertyMetadata": {
        "ZoneId": "${VSwitchZoneId}",
        "VpcId": "${VpcId}"
      }
    }
  },
  "Resources": {
    "VpcBinder": {
      "Type": "ALIYUN::OTS::VpcBinder",
      "Properties": {
        "InstanceName": {
          "Ref": "InstanceName"
        },
        "Vpcs": [
          {
            "VpcId": {
              "Ref": "VpcId"
            },
            "InstanceVpcName": {
              "Ref": "InstanceVpcName"
            },
            "VirtualSwitchId": {
              "Ref": "VSwitchZoneId"
            },
            "Network": "NORMAL"
          }
        ]
      }
    }
  },
  "Outputs": {
    "Domains": {
      "Value": {
        "Fn::GetAtt": [
          "VpcBinder",
          "Domains"
        ]
      }
    },
    "Endpoints": {
      "Value": {
        "Fn::GetAtt": [
          "VpcBinder",
          "Endpoints"
        ]
      }
    }
  }
}