Interroge les vSwitch existants.
Syntaxe
{
"Type": "DATASOURCE::VPC::VSwitches",
"Properties": {
"IsDefault": Boolean,
"DhcpOptionsSetId": String,
"RouteTableId": String,
"VpcId": String,
"ResourceGroupId": String,
"VSwitchIds": List,
"VSwitchOwnerId": String,
"VSwitchName": String,
"RefreshOptions": String
}
}
Propriétés
|
Propriété |
Type |
Obligatoire |
Modifiable |
Description |
Contrainte |
|
IsDefault |
Boolean |
Non |
Oui |
Indique s'il faut interroger le vSwitch par défaut dans la région de la pile. |
Valeurs valides :
|
|
DhcpOptionsSetId |
String |
Non |
Oui |
ID de l'ensemble d'options DHCP. |
Aucune. |
|
RouteTableId |
String |
Non |
Oui |
ID de la table de routage. |
Aucune. |
|
VpcId |
String |
Non |
Oui |
ID du VPC auquel appartient le vSwitch. |
Aucune. |
|
ResourceGroupId |
String |
Non |
Oui |
ID du groupe de ressources auquel appartient le vSwitch. |
Aucune. |
|
|
List |
Non |
Oui |
ID des vSwitch. |
Spécifiez jusqu'à 20 ID de vSwitch. |
|
|
String |
Non |
Oui |
ID du compte Alibaba Cloud auquel appartient le vSwitch. |
Aucune. |
|
|
String |
Non |
Oui |
Nom du vSwitch. |
Aucune. |
|
RefreshOptions |
String |
Non |
Oui |
Politique d'actualisation des ressources de source de données lors de la mise à jour de la pile. |
Valeurs valides :
|
Valeurs de retour (Fn::GetAtt)
VSwitchIds: ID des vSwitch.VSwitches: détails des vSwitch.
|
Propriété |
Type |
Description |
Contrainte |
|
|
List |
ID des vSwitch. |
Exemple : |
|
|
List |
Détails des vSwitch. |
Aucune. |
|
VpcId |
String |
ID du VPC auquel appartient le vSwitch. |
Exemple : |
|
Status |
String |
État du vSwitch. |
Valeurs valides :
|
|
IsDefault |
Boolean |
Indique si le vSwitch est le vSwitch par défaut. |
Valeurs valides :
|
|
AvailableIpAddressCount |
String |
Nombre d'adresses IP disponibles dans le vSwitch. |
Aucune. |
|
NetworkAclId |
String |
ID de la liste de contrôle d'accès réseau (ACL). |
Exemple : |
|
|
String |
ID du vSwitch. |
Exemple : |
|
CidrBlock |
String |
Bloc CIDR IPv4 du vSwitch. |
Aucune. |
|
Description |
String |
Description du vSwitch. |
Aucune. |
|
ResourceGroupId |
String |
ID du groupe de ressources auquel appartient le vSwitch. |
Exemple : |
|
ZoneId |
String |
Zone à laquelle appartient le vSwitch. |
Aucune. |
|
Ipv6CidrBlock |
String |
Bloc CIDR IPv6 du vSwitch. |
Aucune. |
|
|
String |
Nom du vSwitch. |
Aucune. |
|
Tags |
List |
Tags du vSwitch. |
Exemple :
|
|
RouteTable |
List |
Détails de la table de routage. |
Exemple :
|
Exemples
ROSTemplateFormatVersion: '2015-09-01'
Parameters:
VpcId:
AssociationProperty: ALIYUN::ECS::VPC::VPCId
Type: String
Description: Please search the ID starts with (vpc-xxx)from console-Virtual Private Cloud
Label: Existing VPC Instance ID
Resources:
ExtensionDataSource:
Type: DATASOURCE::VPC::VSwitches
Properties:
VpcId:
Ref: VpcId
Outputs:
VSwitchIds:
Description: The list of The vSwitch Ids.
Value:
Fn::GetAtt:
- ExtensionDataSource
- VSwitchIds
VSwitches:
Description: The detailed information about the vSwitches.
Value:
Fn::GetAtt:
- ExtensionDataSource
- VSwitches{
"ROSTemplateFormatVersion": "2015-09-01",
"Parameters": {
"VpcId": {
"AssociationProperty": "ALIYUN::ECS::VPC::VPCId",
"Type": "String",
"Description": "Please search the ID starts with (vpc-xxx)from console-Virtual Private Cloud",
"Label": "Existing VPC Instance ID"
}
},
"Resources": {
"ExtensionDataSource": {
"Type": "DATASOURCE::VPC::VSwitches",
"Properties": {
"VpcId": {
"Ref": "VpcId"
}
}
}
},
"Outputs": {
"VSwitchIds": {
"Description": "The list of The vSwitch Ids.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"VSwitchIds"
]
}
},
"VSwitches": {
"Description": "The detailed information about the vSwitches.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"VSwitches"
]
}
}
}
}