O recurso ALIYUN::VPC::VpnGateway cria um VPN gateway.
Sintaxe
{
"Type": "ALIYUN::VPC::VpnGateway",
"Properties": {
"VpcId": String,
"VSwitchId": String,
"Description": String,
"EnableIpsec": Boolean,
"AutoPay": Boolean,
"Period": Integer,
"EnableSsl": Boolean,
"Bandwidth": Integer,
"InstanceChargeType": String,
"SslConnections": Integer,
"Name": String,
"Tags": List,
"VpnType": String,
"NetworkType": String,
"DisasterRecoveryVSwitchId": String,
"ResourceGroupId": String
}
}
Propriedades
|
Parâmetro |
Tipo |
Obrigatório |
Atualização permitida |
Descrição |
Restrições |
|
VpcId |
String |
Sim |
Não |
ID da VPC do VPN gateway. |
Nenhuma. |
|
VSwitchId |
String |
Não |
Não |
ID do vSwitch associado ao VPN gateway. |
Nenhuma. |
|
Description |
String |
Não |
Sim |
Descrição do VPN gateway. |
A descrição deve ter de 2 a 256 caracteres, começar com uma letra ou caractere chinês e não pode iniciar com |
|
EnableIpsec |
Boolean |
Não |
Não |
Indica se o recurso IPsec-VPN está ativado. |
Valores válidos:
O IPsec-VPN fornece conexões site a site. Crie um túnel IPsec para conectar com segurança um data center on-premises a uma VPC ou conectar duas VPCs. |
|
AutoPay |
Boolean |
Não |
Não |
Indica se o pagamento automático da assinatura está ativado. |
Valores válidos:
|
|
Period |
Integer |
Não |
Não |
Duração da assinatura. |
Valores válidos:
Unidade: mês. Este parâmetro é obrigatório quando |
|
EnableSsl |
Boolean |
Não |
Não |
Indica se o recurso SSL-VPN está ativado. |
Valores válidos:
O SSL-VPN oferece conexões VPN ponto a site que permitem a conexão direta de clientes ao VPN gateway sem a configuração de um customer gateway. |
|
Bandwidth |
Integer |
Sim |
Não |
Largura de banda pública do VPN gateway. |
Valores válidos:
Unidade: Mbit/s. |
|
InstanceChargeType |
String |
Não |
Não |
Método de faturamento do VPN gateway. |
O valor deve ser |
|
SslConnections |
Integer |
Não |
Não |
Número máximo de conexões simultâneas de clientes SSL-VPN. |
Nenhuma. |
|
ResourceGroupId |
String |
Não |
Sim |
ID do grupo de recursos. |
Nenhuma. |
|
Name |
String |
Não |
Sim |
Nome do VPN gateway. |
O nome deve ter de 2 a 100 caracteres. Deve começar com uma letra ou caractere chinês e pode conter letras, caracteres chineses, dígitos, sublinhados (_) e hífens (-). O nome não pode começar com Se este parâmetro não for especificado, o sistema usará o ID do VPN gateway como nome. |
|
Tags |
List |
Não |
Sim |
Tags a serem adicionadas ao VPN gateway. |
É possível adicionar até 20 tags. Para mais informações, consulte a seção Propriedades de tag. |
|
VpnType |
String |
Não |
Não |
Tipo do VPN gateway. |
Valores válidos:
|
|
NetworkType |
String |
Não |
Não |
Tipo de rede do VPN gateway. |
Valores válidos:
|
|
DisasterRecoveryVSwitchId |
String |
Não |
Não |
ID do vSwitch secundário associado ao VPN gateway. |
Para obter informações sobre as regiões e zonas de disponibilidade que suportam o modo de túnel duplo para conexões IPsec-VPN, consulte Atualizar uma conexão IPsec-VPN para o modo de túnel duplo. |
Sintaxe de tag
"Tags": [
{
"Key": String,
"Value": String
}
]
Propriedades de tag
|
Parâmetro |
Tipo |
Obrigatório |
Atualização permitida |
Descrição |
Restrições |
|
Key |
String |
Sim |
Não |
Chave da tag. |
A chave da tag pode ter de 1 a 128 caracteres. Não pode começar com |
|
Value |
String |
Não |
Não |
Valor da tag. |
O valor da tag pode ter de 0 a 128 caracteres. Não pode começar com |
Valores de retorno
Fn::GetAtt
OrderId: ID do pedido.VpnGatewayId: ID do VPN gateway.InternetIp: endereço IP público do VPN gateway.SslMaxConnections: número máximo de conexões SSL-VPN simultâneas.Spec: largura de banda máxima do VPN gateway.DisasterRecoveryVSwitchId: ID do vSwitch secundário associado ao VPN gateway.VpnType: tipo do VPN gateway.VpcId: ID da VPC do VPN gateway.SslVpnInternetIp: endereço IP público da conexão SSL-VPN.DisasterRecoveryInternetIp: endereço IP público secundário atribuído à conexão IPsec-VPN no modo de túnel duplo.VSwitchId: ID do vSwitch associado ao VPN gateway.Arn: Alibaba Cloud Resource Name (ARN) do VPN gateway.
Exemplos
ROSTemplateFormatVersion: '2015-09-01'
Parameters:
AutoPay:
AllowedValues:
- 'True'
- 'true'
- 'False'
- 'false'
Default: true
Description: 'Specifies whether to automatically pay for the vpn gateway. Valid values:
True (default): Automatically pays for the vpn gateway.
False: Does not automatically pay for the vpn gateway.'
Type: Boolean
Bandwidth:
AllowedValues:
- 5
- 10
- 20
- 50
- 100
- 200
Description: 'The public bandwidth of the vpn gateway, in Mbit/s.
Valid values: 5, 10, 20, 50, 100, and 200.'
Type: Number
Description:
Description: 'A description of the vpn gateway.
The description must be 2 to 256 characters long, start with a letter or a Chinese character,
and must not start with http:// or https://.'
MaxLength: 256
MinLength: 2
Type: String
EnableIpsec:
AllowedValues:
- 'True'
- 'true'
- 'False'
- 'false'
Default: true
Description: 'Specifies whether to enable the IPsec-VPN feature. The IPsec-VPN feature provides
site-to-site connections. You can create an IPsec tunnel to securely connect your on-premises
data center to a VPC or to connect two VPCs. Valid values:
True (default): Enables the IPsec-VPN feature.
False: Disables the IPsec-VPN feature.'
Type: Boolean
EnableSsl:
AllowedValues:
- 'True'
- 'true'
- 'False'
- 'false'
Default: false
Description: 'Specifies whether to enable the SSL-VPN feature. This feature provides point-to-site VPN
connections, which allow clients to connect to the vpn gateway without the need
to configure a customer gateway. Valid values:
True: Enables the SSL-VPN feature.
False (default): Disables the SSL-VPN feature.'
Type: Boolean
InstanceChargeType:
AllowedValues:
- PREPAY
- POSTPAY
Default: PREPAY
Description: 'The billing method of the vpn gateway. Valid values are:
PREPAY, POSTPAY'
Type: String
Name:
Description: 'The name of the vpn gateway. If you do not specify this parameter, the ID of the vpn
gateway is used as its name.
The name must be 2 to 100 characters in length. It must start with a letter
or a Chinese character, can contain digits, underscores (_), and hyphens
(-), and cannot start with http:// or https://.'
MaxLength: 100
MinLength: 2
Type: String
Period:
AllowedValues:
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 12
- 24
- 36
Description: 'The subscription duration, in months. Valid values: 1, 2, 3, 4, 5, 6, 7, 8, 9, 12, 24, and 36.
This parameter is required when InstanceChargeType is set to PREPAY.'
Type: Number
SslConnections:
Description: The maximum number of clients allowed to connect at the same time.
Type: Number
Tags:
Description: The tags to add to the instance. You can add a maximum of 20 tags.
Each tag consists of a key and a value, and the key is required.
MaxLength: 20
Type: Json
VSwitchId:
Description: The ID of the VSwitch to which the VPN gateway belongs.
Type: String
VpcId:
Description: The ID of the VPC to which the VPN gateway belongs.
Type: String
Resources:
VpnGateway:
Properties:
AutoPay:
Ref: AutoPay
Bandwidth:
Ref: Bandwidth
Description:
Ref: Description
EnableIpsec:
Ref: EnableIpsec
EnableSsl:
Ref: EnableSsl
InstanceChargeType:
Ref: InstanceChargeType
Name:
Ref: Name
Period:
Ref: Period
SslConnections:
Ref: SslConnections
Tags:
Ref: Tags
VSwitchId:
Ref: VSwitchId
VpcId:
Ref: VpcId
Type: ALIYUN::VPC::VpnGateway
Outputs:
InternetIp:
Description: The public IP address of the VPN gateway.
Value:
Fn::GetAtt:
- VpnGateway
- InternetIp
OrderId:
Description: The order ID.
Value:
Fn::GetAtt:
- VpnGateway
- OrderId
Spec:
Description: The specification of the VPN gateway.
Value:
Fn::GetAtt:
- VpnGateway
- Spec
SslMaxConnections:
Description: The maximum number of concurrent SSL-VPN connections.
Value:
Fn::GetAtt:
- VpnGateway
- SslMaxConnections
VpnGatewayId:
Description: The ID of the vpn gateway.
Value:
Fn::GetAtt:
- VpnGateway
- VpnGatewayId
{
"ROSTemplateFormatVersion": "2015-09-01",
"Parameters": {
"EnableIpsec": {
"Type": "Boolean",
"Description": "Specifies whether to enable the IPsec-VPN feature. The IPsec-VPN feature provides site-to-site connections. You can create an IPsec tunnel to securely connect your on-premises data center to a VPC or to connect two VPCs. Valid values:\nTrue (default): Enables the IPsec-VPN feature.\nFalse: Disables the IPsec-VPN feature.",
"AllowedValues": [
"True",
"true",
"False",
"false"
],
"Default": true
},
"EnableSsl": {
"Type": "Boolean",
"Description": "Specifies whether to enable the SSL-VPN feature. This feature provides point-to-site VPN connections, which allow clients to connect to the vpn gateway without the need to configure a customer gateway. Valid values:\nTrue: Enables the SSL-VPN feature.\nFalse (default): Disables the SSL-VPN feature.",
"AllowedValues": [
"True",
"true",
"False",
"false"
],
"Default": false
},
"SslConnections": {
"Type": "Number",
"Description": "The maximum number of clients allowed to connect at the same time."
},
"Description": {
"Type": "String",
"Description": "A description of the vpn gateway.\nThe description must be 2 to 256 characters long, start with a letter or a Chinese character, and must not start with http:// or https://.",
"MinLength": 2,
"MaxLength": 256
},
"VpcId": {
"Type": "String",
"Description": "The ID of the VPC to which the VPN gateway belongs."
},
"InstanceChargeType": {
"Type": "String",
"Description": "The billing method of the vpn gateway. Valid values are:\nPREPAY, POSTPAY",
"AllowedValues": [
"PREPAY",
"POSTPAY"
],
"Default": "PREPAY"
},
"Bandwidth": {
"Type": "Number",
"Description": "The public bandwidth of the vpn gateway, in Mbit/s.\nValid values: 5, 10, 20, 50, 100, and 200.",
"AllowedValues": [
5,
10,
20,
50,
100,
200
]
},
"VSwitchId": {
"Type": "String",
"Description": "The ID of the VSwitch to which the VPN gateway belongs."
},
"Period": {
"Type": "Number",
"Description": "The subscription duration, in months. Valid values: 1, 2, 3, 4, 5, 6, 7, 8, 9, 12, 24, and 36.\nThis parameter is required when InstanceChargeType is set to PREPAY.",
"AllowedValues": [
1,
2,
3,
4,
5,
6,
7,
8,
9,
12,
24,
36
]
},
"AutoPay": {
"Type": "Boolean",
"Description": "Specifies whether to automatically pay for the vpn gateway. Valid values:\nTrue (default): Automatically pays for the vpn gateway.\nFalse: Does not automatically pay for the vpn gateway.",
"AllowedValues": [
"True",
"true",
"False",
"false"
],
"Default": true
},
"Tags": {
"Type": "Json",
"Description": "The tags to add to the instance. You can add a maximum of 20 tags. Each tag consists of a key and a value, and the key is required.",
"MaxLength": 20
},
"Name": {
"Type": "String",
"Description": "The name of the vpn gateway. If you do not specify this parameter, the ID of the vpn gateway is used as its name.\nThe name must be 2 to 100 characters in length. It must start with a letter or a Chinese character, can contain digits, underscores (_), and hyphens (-), and cannot start with http:// or https://.",
"MinLength": 2,
"MaxLength": 100
}
},
"Resources": {
"VpnGateway": {
"Type": "ALIYUN::VPC::VpnGateway",
"Properties": {
"EnableIpsec": {
"Ref": "EnableIpsec"
},
"EnableSsl": {
"Ref": "EnableSsl"
},
"SslConnections": {
"Ref": "SslConnections"
},
"Description": {
"Ref": "Description"
},
"VpcId": {
"Ref": "VpcId"
},
"InstanceChargeType": {
"Ref": "InstanceChargeType"
},
"Bandwidth": {
"Ref": "Bandwidth"
},
"VSwitchId": {
"Ref": "VSwitchId"
},
"Period": {
"Ref": "Period"
},
"AutoPay": {
"Ref": "AutoPay"
},
"Tags": {
"Ref": "Tags"
},
"Name": {
"Ref": "Name"
}
}
}
},
"Outputs": {
"InternetIp": {
"Description": "The public IP address of the VPN gateway.",
"Value": {
"Fn::GetAtt": [
"VpnGateway",
"InternetIp"
]
}
},
"VpnGatewayId": {
"Description": "The ID of the vpn gateway.",
"Value": {
"Fn::GetAtt": [
"VpnGateway",
"VpnGatewayId"
]
}
},
"OrderId": {
"Description": "The order ID.",
"Value": {
"Fn::GetAtt": [
"VpnGateway",
"OrderId"
]
}
},
"Spec": {
"Description": "The specification of the VPN gateway.",
"Value": {
"Fn::GetAtt": [
"VpnGateway",
"Spec"
]
}
},
"SslMaxConnections": {
"Description": "The maximum number of concurrent SSL-VPN connections.",
"Value": {
"Fn::GetAtt": [
"VpnGateway",
"SslMaxConnections"
]
}
}
}
}