O recurso ALIYUN::VPC::GrantInstanceToCen autoriza uma instância CEN.
Sintaxe
{
"Type": "ALIYUN::VPC::GrantInstanceToCen",
"Properties": {
"InstanceId": String,
"CenOwnerId": Integer,
"CenId": String,
"InstanceType": String
}
}
Propriedades
Propriedade | Tipo de dados | Obrigatório | Editável | Descrição | Restrição |
InstanceId | String | Sim | Não | ID da instância de rede. | Nenhuma |
CenOwnerId | Integer | Sim | Não | UID da conta à qual a instância Cloud Enterprise Network pertence. | Nenhuma |
CenId | String | Sim | Não | ID da instância Cloud Enterprise Network a autorizar. | Nenhuma |
InstanceType | String | Sim | Não | Tipo da rede anexada. | Valores válidos:
|
Parâmetros de resposta
Fn::GetAtt
InstanceId: ID da instância de rede.
CenId: ID da instância Cloud Enterprise Network.
Exemplo
Formato JSON
{
"ROSTemplateFormatVersion": "2015-09-01",
"Parameters": {
"InstanceId": {
"Type": "String",
"Description": "The ID of the network instance."
},
"CenOwnerId": {
"Type": "Number",
"Description": "The UID of the account to which the target CEN instance belongs."
},
"CenId": {
"Type": "String",
"Description": "The ID of the CEN instance to be authorized."
},
"InstanceType": {
"Type": "String",
"Description": "The type of the network instance. Valid values:\nVPC: Virtual Private Cloud (VPC).\nVBR: Virtual Border Router (VBR).\nCCN: Cloud Connect Network (CCN).",
"AllowedValues": [
"CCN",
"VBR",
"VPC"
]
}
},
"Resources": {
"GrantInstanceToCen": {
"Type": "ALIYUN::VPC::GrantInstanceToCen",
"Properties": {
"InstanceId": {
"Ref": "InstanceId"
},
"CenOwnerId": {
"Ref": "CenOwnerId"
},
"CenId": {
"Ref": "CenId"
},
"InstanceType": {
"Ref": "InstanceType"
}
}
}
},
"Outputs": {
"InstanceId": {
"Description": "The ID of the network instance.",
"Value": {
"Fn::GetAtt": [
"GrantInstanceToCen",
"InstanceId"
]
}
},
"CenId": {
"Description": "The ID of the CEN instance to be authorized.",
"Value": {
"Fn::GetAtt": [
"GrantInstanceToCen",
"CenId"
]
}
}
}
}
Formato YAML
ROSTemplateFormatVersion: '2015-09-01'
Parameters:
InstanceId:
Type: String
Description: The ID of the network instance.
CenOwnerId:
Type: Number
Description: The UID of the account to which the target CEN instance belongs.
CenId:
Type: String
Description: The ID of the CEN instance to be authorized.
InstanceType:
Type: String
Description: |-
The type of the network instance. Valid values:
VPC: Virtual Private Cloud (VPC).
VBR: Virtual Border Router (VBR).
CCN: Cloud Connect Network (CCN).
AllowedValues:
-CCN
-VBR
- VPC
Resources:
GrantInstanceToCen:
Type: 'ALIYUN::VPC::GrantInstanceToCen'
Properties:
InstanceId:
Ref: InstanceId
CenOwnerId:
Ref: CenOwnerId
CenId:
Ref: CenId
InstanceType:
Ref: InstanceType
Outputs:
InstanceId:
Description: The ID of the network instance.
Value:
'Fn::GetAtt':
-GrantInstanceToCen
- InstanceId
CenId:
Description: The ID of the CEN instance to be authorized.
Value:
'Fn::GetAtt':
-GrantInstanceToCen
-CenId