ALIYUN::DNS::Instance类型用于创建云解析DNS实例。
语法
{
"Type": "ALIYUN::DNS::Instance",
"Properties": {
"DomainNumbers": Integer,
"DNSSecurity": String,
"Version": String,
"RenewalStatus": String,
"Period": Integer,
"Domain": String,
"InstanceType": String,
"PeriodUnit": String
}
}
属性
属性名称 | 类型 | 必须 | 允许更新 | 描述 | 约束 |
DomainNumbers | Integer | 是 | 否 | 域名数量。 | 取值范围:1~100。 |
DNSSecurity | String | 是 | 否 | DNS安全。 | 取值:
|
Version | String | 是 | 是 | 阿里云DNS版本。 | 取值:
说明 创建实例后只支持升级操作。 |
RenewalStatus | String | 否 | 否 | 更新状态。 | 取值:
|
Period | Integer | 是 | 否 | 自动续费时长。 | PeriodUnit取值为Year,取值范围:1、2。3 PeriodUnit取值为Month,取值范围:1、2、3、6。 |
Domain | String | 否 | 否 | 绑定域名名称。 | 当需要绑定多个域名时,多个域名之间用“,”隔开。 |
InstanceType | String | 否 | 否 | 实例类型。 | 取值:
|
PeriodUnit | String | 是 | 否 | 自动续费周期单位。 | 取值:
|
返回值
Fn::GetAtt
InstanceId:DNS实例ID。
示例
YAML
格式ROSTemplateFormatVersion: '2015-09-01' Parameters: DNSSecurity: AllowedValues: - 'no' - basic - advanced Description: en: 'The DNS security policy. Valid values: - no: No protection against DNS attacks is provided. - basic: Basic protection against DNS attacks is provided. - advanced: Advanced protection against DNS attacks is provided.' Required: true Type: String Domain: Description: en: The domain name that you want to bind to the instance. If you want to bind multiple domain names to the instance, separate these domain names with commas (,). Required: false Type: String DomainNumbers: Description: en: The number of domain names. MaxValue: 100 MinValue: 1 Required: true Type: Number InstanceType: AllowedValues: - HostedPublicZone - CachedPublicZone Default: HostedPublicZone Description: en: 'The type of the instance. Valid values: - HostedPublicZone: Hosted Public Zone - CachedPublicZone: Cached Public Zone.' Required: false Type: String Period: AllowedValues: - 1 - 2 - 3 - 6 AssociationProperty: PayPeriod Description: en: 'The subscription duration. Valid values: - If unit is month: 1, 2, 3, 6 - If unit is year: 1, 2, 3' Required: true Type: Number PeriodUnit: AllowedValues: - Year - Month AssociationProperty: PayPeriodUnit Description: en: The subscription duration unit. Required: true Type: String RenewalStatus: AllowedValues: - AutoRenewal - ManualRenewal Default: ManualRenewal Description: en: 'The renewal method. Valid values: - AutoRenewal: The instance is automatically renewed. - ManualRenewal: The instance is manually renewed. Default value: ManualRenewal.' Required: false Type: String Version: AllowedValues: - version_personal - version_enterprise_basic - version_enterprise_advanced - version_cached_basic Description: en: "The edition of Alibaba Cloud DNS. Valid values:\nIf create hosted public\ \ zone:\n- version_personal: Personal Edition. \n- version_enterprise_basic:\ \ Enterprise Standard Edition. \n- version_enterprise_advanced: Enterprise\ \ Ultimate Edition.\nIf create cached public zone:\n- version_cached_basic**Note**:\ \ Only upgrade operations are supported after instance creation." Required: true Type: String Resources: Instance: Properties: DNSSecurity: Ref: DNSSecurity Domain: Ref: Domain DomainNumbers: Ref: DomainNumbers InstanceType: Ref: InstanceType Period: Ref: Period PeriodUnit: Ref: PeriodUnit RenewalStatus: Ref: RenewalStatus Version: Ref: Version Type: ALIYUN::DNS::Instance Outputs: InstanceId: Description: DNS instance id. Value: Fn::GetAtt: - Instance - InstanceId
JSON
格式{ "ROSTemplateFormatVersion": "2015-09-01", "Parameters": { "DomainNumbers": { "Type": "Number", "Description": { "en": "The number of domain names." }, "Required": true, "MinValue": 1, "MaxValue": 100 }, "DNSSecurity": { "Type": "String", "Description": { "en": "The DNS security policy. Valid values:\n- no: No protection against DNS attacks is provided.\n- basic: Basic protection against DNS attacks is provided.\n- advanced: Advanced protection against DNS attacks is provided." }, "AllowedValues": [ "no", "basic", "advanced" ], "Required": true }, "Version": { "Type": "String", "Description": { "en": "The edition of Alibaba Cloud DNS. Valid values:\nIf create hosted public zone:\n- version_personal: Personal Edition. \n- version_enterprise_basic: Enterprise Standard Edition. \n- version_enterprise_advanced: Enterprise Ultimate Edition.\nIf create cached public zone:\n- version_cached_basic**Note**: Only upgrade operations are supported after instance creation." }, "AllowedValues": [ "version_personal", "version_enterprise_basic", "version_enterprise_advanced", "version_cached_basic" ], "Required": true }, "RenewalStatus": { "Type": "String", "Description": { "en": "The renewal method. Valid values:\n- AutoRenewal: The instance is automatically renewed.\n- ManualRenewal: The instance is manually renewed.\nDefault value: ManualRenewal." }, "AllowedValues": [ "AutoRenewal", "ManualRenewal" ], "Required": false, "Default": "ManualRenewal" }, "Period": { "AssociationProperty": "PayPeriod", "Type": "Number", "Description": { "en": "The subscription duration. Valid values:\n- If unit is month: 1, 2, 3, 6\n- If unit is year: 1, 2, 3" }, "AllowedValues": [ 1, 2, 3, 6 ], "Required": true }, "Domain": { "Type": "String", "Description": { "en": "The domain name that you want to bind to the instance. If you want to bind multiple domain names to the instance, separate these domain names with commas (,)." }, "Required": false }, "InstanceType": { "Type": "String", "Description": { "en": "The type of the instance. Valid values:\n- HostedPublicZone: Hosted Public Zone\n- CachedPublicZone: Cached Public Zone." }, "AllowedValues": [ "HostedPublicZone", "CachedPublicZone" ], "Required": false, "Default": "HostedPublicZone" }, "PeriodUnit": { "AssociationProperty": "PayPeriodUnit", "Type": "String", "Description": { "en": "The subscription duration unit." }, "AllowedValues": [ "Year", "Month" ], "Required": true } }, "Resources": { "Instance": { "Type": "ALIYUN::DNS::Instance", "Properties": { "DomainNumbers": { "Ref": "DomainNumbers" }, "DNSSecurity": { "Ref": "DNSSecurity" }, "Version": { "Ref": "Version" }, "RenewalStatus": { "Ref": "RenewalStatus" }, "Period": { "Ref": "Period" }, "Domain": { "Ref": "Domain" }, "InstanceType": { "Ref": "InstanceType" }, "PeriodUnit": { "Ref": "PeriodUnit" } } } }, "Outputs": { "InstanceId": { "Description": "DNS instance id.", "Value": { "Fn::GetAtt": [ "Instance", "InstanceId" ] } } } }
文档内容是否对您有帮助?