Consulta os detalhes de uma Virtual Private Cloud (VPC).
Sintaxe
{
"Type": "DATASOURCE::VPC::Vpc",
"Properties": {
"VpcId": String,
"RefreshOptions": String
}
}
Propriedades
|
Propriedade |
Tipo |
Obrigatório |
Editável |
Descrição |
Restrição |
|
VpcId |
String |
Sim |
Sim |
ID da VPC. |
Nenhuma. |
|
RefreshOptions |
String |
Não |
Sim |
Política de atualização dos recursos da fonte de dados ao atualizar a pilha. |
Valores válidos:
|
Valores de retorno
Fn::GetAtt
IsDefault: indica se a VPC é a padrão na região especificada.
Description: descrição da VPC.
ClassicLinkEnabled: estado do ClassicLink da VPC.
ResourceGroupId: ID do grupo de recursos ao qual a VPC pertence.
SecondaryCidrBlocks: blocos CIDR secundários da VPC.
VSwitchIds: vSwitches na VPC.
CreateTime: horário de criação da VPC.
RouterId: ID do roteador da VPC.
CidrBlock: bloco CIDR IPv4 da VPC.
UserCidrs: blocos CIDR de usuário da VPC.
DhcpOptionsSetId: ID do conjunto de opções do Dynamic Host Configuration Protocol (DHCP).
VpcId: ID da VPC.
VpcName: nome da VPC.
Ipv6CidrBlock: bloco CIDR IPv6 da VPC.
Ipv6CidrBlocks: blocos CIDR IPv6 da VPC.
Tags: tags da VPC.
Exemplos
ROSTemplateFormatVersion: '2015-09-01'
Parameters:
VpcId:
AssociationProperty: ALIYUN::ECS::VPC::VPCId
Type: String
Description:
en: The ID of the VPC.
Required: true
Resources:
ExtensionDataSource:
Type: DATASOURCE::VPC::Vpc
Properties:
VpcId:
Ref: VpcId
Outputs:
IsDefault:
Description: |-
Indicates whether to query the default VPC in the specified region. Valid values:
- true (default): All VPCs in the specified region are queried.
- false: The default VPC is not queried.
Value:
Fn::GetAtt:
- ExtensionDataSource
- IsDefault
Description:
Description: The description of the VPC.
Value:
Fn::GetAtt:
- ExtensionDataSource
- Description
ClassicLinkEnabled:
Description: status of vpc ClassicLink..
Value:
Fn::GetAtt:
- ExtensionDataSource
- ClassicLinkEnabled
ResourceGroupId:
Description: The ID of the resource group to which the VPC belongs.
Value:
Fn::GetAtt:
- ExtensionDataSource
- ResourceGroupId
SecondaryCidrBlocks:
Description: Additional network segment information.
Value:
Fn::GetAtt:
- ExtensionDataSource
- SecondaryCidrBlocks
VSwitchIds:
Description: A list of VSwitches in the VPC.
Value:
Fn::GetAtt:
- ExtensionDataSource
- VSwitchIds
CreateTime:
Description: The time at which the VPC was created.
Value:
Fn::GetAtt:
- ExtensionDataSource
- CreateTime
RouterId:
Description: The ID of the VRouter.
Value:
Fn::GetAtt:
- ExtensionDataSource
- RouterId
CidrBlock:
Description: The IPv4 CIDR block of the VPC.
Value:
Fn::GetAtt:
- ExtensionDataSource
- CidrBlock
UserCidrs:
Description: A list of user CIDRs.
Value:
Fn::GetAtt:
- ExtensionDataSource
- UserCidrs
DhcpOptionsSetId:
Description: The ID of the DHCP option set.
Value:
Fn::GetAtt:
- ExtensionDataSource
- DhcpOptionsSetId
VpcId:
Description: The ID of the VPC.
Value:
Fn::GetAtt:
- ExtensionDataSource
- VpcId
VpcName:
Description: The name of the VPC.
Value:
Fn::GetAtt:
- ExtensionDataSource
- VpcName
Ipv6CidrBlock:
Description: The ipv6 cidr block of vpc.
Value:
Fn::GetAtt:
- ExtensionDataSource
- Ipv6CidrBlock
Ipv6CidrBlocks:
Description: The IPv6 network segment of the VPC.
Value:
Fn::GetAtt:
- ExtensionDataSource
- Ipv6CidrBlocks
Tags:
Description: The tags of Vpc.
Value:
Fn::GetAtt:
- ExtensionDataSource
- Tags
{
"ROSTemplateFormatVersion": "2015-09-01",
"Parameters": {
"VpcId": {
"AssociationProperty": "ALIYUN::ECS::VPC::VPCId",
"Type": "String",
"Description": {
"en": "The ID of the VPC."
},
"Required": true
}
},
"Resources": {
"ExtensionDataSource": {
"Type": "DATASOURCE::VPC::Vpc",
"Properties": {
"VpcId": {
"Ref": "VpcId"
}
}
}
},
"Outputs": {
"IsDefault": {
"Description": "Indicates whether to query the default VPC in the specified region. Valid values: \n- true (default): All VPCs in the specified region are queried.\n- false: The default VPC is not queried.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"IsDefault"
]
}
},
"Description": {
"Description": "The description of the VPC.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"Description"
]
}
},
"ClassicLinkEnabled": {
"Description": "status of vpc ClassicLink..",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"ClassicLinkEnabled"
]
}
},
"ResourceGroupId": {
"Description": "The ID of the resource group to which the VPC belongs.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"ResourceGroupId"
]
}
},
"SecondaryCidrBlocks": {
"Description": "Additional network segment information.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"SecondaryCidrBlocks"
]
}
},
"VSwitchIds": {
"Description": "A list of VSwitches in the VPC.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"VSwitchIds"
]
}
},
"CreateTime": {
"Description": "The time at which the VPC was created.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"CreateTime"
]
}
},
"RouterId": {
"Description": "The ID of the VRouter.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"RouterId"
]
}
},
"CidrBlock": {
"Description": "The IPv4 CIDR block of the VPC.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"CidrBlock"
]
}
},
"UserCidrs": {
"Description": "A list of user CIDRs.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"UserCidrs"
]
}
},
"DhcpOptionsSetId": {
"Description": "The ID of the DHCP option set.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"DhcpOptionsSetId"
]
}
},
"VpcId": {
"Description": "The ID of the VPC.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"VpcId"
]
}
},
"VpcName": {
"Description": "The name of the VPC.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"VpcName"
]
}
},
"Ipv6CidrBlock": {
"Description": "The ipv6 cidr block of vpc.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"Ipv6CidrBlock"
]
}
},
"Ipv6CidrBlocks": {
"Description": "The IPv6 network segment of the VPC.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"Ipv6CidrBlocks"
]
}
},
"Tags": {
"Description": "The tags of Vpc.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"Tags"
]
}
}
}
}