Cria uma regra de agendamento para o Sec-Traffic Manager.
Sintaxe
{
"Type": "ALIYUN::DDoSPro::SchedulerRule",
"Properties": {
"ResourceGroupId": String,
"Param": String,
"RuleType": Integer,
"Rules": String,
"RuleName": String
}
}
Propriedades
|
Propriedade |
Tipo |
Obrigatório |
Editável |
Descrição |
Restrição |
|
RuleName |
String |
Sim |
Não |
Nome da regra de agendamento. |
Nenhuma. |
|
Rules |
String |
Sim |
Não |
Detalhes da regra de agendamento em formato de string JSON. |
O valor de Rules contém os seguintes campos:
|
|
RuleType |
Integer |
Sim |
Não |
Tipo da regra de agendamento. |
Valores válidos:
|
|
Param |
String |
Não |
Não |
Detalhes da regra de interação com CDN em formato de string JSON. |
O valor de Param contém os seguintes campos:
Exemplo:
|
|
ResourceGroupId |
String |
Não |
Não |
ID do grupo de recursos da instância Anti-DDoS Proxy. |
Valor padrão: vazio (indica o grupo de recursos padrão). |
Valores de retorno
Fn::GetAtt
RuleName: nome da regra de agendamento.
Exemplos
Formato YAML
ROSTemplateFormatVersion: '2015-09-01'
Parameters:
RuleType:
Type: Number
Description:
en: |-
The type of the custom defense rule. Valid values:
2: tiered protection
3: network acceleration
5: CDN interaction
6: cloud service interaction
Required: true
Rules:
Type: String
Description:
en: |-
The details of the scheduling rule. This parameter is a JSON string. The following list describes the fields in the value of the parameter:
Type: the address type of the interaction resource that you want to use in the scheduling rule. This field is required and must be of the string type. Valid values: A: IP address. CNAME: domain name
Value: the address of the interaction resource that you want to use in the scheduling rule. This field is required and must be of the string type.
Priority: the priority of the scheduling rule. This field is required and must be of the integer type. Valid values: 0 to 100. A larger value indicates a higher priority.
ValueType: the type of the interaction resource that you want to use in the scheduling rule. This field is required and must be of the integer type. Valid values: 1: the IP address of the Anti-DDoS Pro or Anti-DDoS Premium instance. 2: the IP address of the interaction resource in the tiered protection scenario. 3: the IP address that is used to accelerate access in the network acceleration scenario. 5: the domain name that is configured in Alibaba Cloud CDN (CDN) in the CDN interaction scenario. 6 the IP address of the interaction resource in the cloud service interaction scenario
RegionId: the region where the interaction resource is deployed. This parameter must be specified when ValueType is set to 2. The value must be of the string type.
Required: true
RuleName:
Type: String
Description:
en: The name of the rule.
Required: true
Resources:
ExtensionResource:
Type: ALIYUN::DDoSPro::SchedulerRule
Properties:
RuleType:
Ref: RuleType
Rules:
Ref: Rules
RuleName:
Ref: RuleName
Outputs:
RuleName:
Description: The name of the rule.
Value:
Fn::GetAtt:
- ExtensionResource
- RuleName
Formato JSON
{
"ROSTemplateFormatVersion": "2015-09-01",
"Parameters": {
"RuleType": {
"Type": "Number",
"Description": {
"en": "The type of the custom defense rule. Valid values: \n2: tiered protection \n3: network acceleration \n5: CDN interaction \n6: cloud service interaction"
},
"Required": true
},
"Rules": {
"Type": "String",
"Description": {
"en": "The details of the scheduling rule. This parameter is a JSON string. The following list describes the fields in the value of the parameter: \nType: the address type of the interaction resource that you want to use in the scheduling rule. This field is required and must be of the string type. Valid values: A: IP address. CNAME: domain name\nValue: the address of the interaction resource that you want to use in the scheduling rule. This field is required and must be of the string type.\nPriority: the priority of the scheduling rule. This field is required and must be of the integer type. Valid values: 0 to 100. A larger value indicates a higher priority.\nValueType: the type of the interaction resource that you want to use in the scheduling rule. This field is required and must be of the integer type. Valid values: 1: the IP address of the Anti-DDoS Pro or Anti-DDoS Premium instance. 2: the IP address of the interaction resource in the tiered protection scenario. 3: the IP address that is used to accelerate access in the network acceleration scenario. 5: the domain name that is configured in Alibaba Cloud CDN (CDN) in the CDN interaction scenario. 6 the IP address of the interaction resource in the cloud service interaction scenario \nRegionId: the region where the interaction resource is deployed. This parameter must be specified when ValueType is set to 2. The value must be of the string type."
},
"Required": true
},
"RuleName": {
"Type": "String",
"Description": {
"en": "The name of the rule."
},
"Required": true
}
},
"Resources": {
"ExtensionResource": {
"Type": "ALIYUN::DDoSPro::SchedulerRule",
"Properties": {
"RuleType": {
"Ref": "RuleType"
},
"Rules": {
"Ref": "Rules"
},
"RuleName": {
"Ref": "RuleName"
}
}
}
},
"Outputs": {
"RuleName": {
"Description": "The name of the rule.",
"Value": {
"Fn::GetAtt": [
"ExtensionResource",
"RuleName"
]
}
}
}
}