ALIYUN::ALB::AccessLogEnable类型用于启用访问日志功能。
语法
{
"Type": "ALIYUN::ALB::AccessLogEnable",
"Properties": {
"LogStore": String,
"LoadBalancerId": String,
"LogProject": String
}
}
属性
|
属性名称 |
类型 |
必须 |
允许更新 |
描述 |
约束 |
|
LoadBalancerId |
String |
是 |
否 |
ALB实例的ID。 |
无 |
|
LogProject |
String |
是 |
否 |
日志项目Project。 |
无 |
|
LogStore |
String |
是 |
否 |
日志库Logstore。 |
无 |
返回值
Fn::GetAtt
无
示例
ROSTemplateFormatVersion: '2015-09-01'
Parameters:
LogStore:
Type: String
Description:
en: The name of the LogHub logstore.
zh: LogHub日志库的名称。
Required: true
LoadBalancerId:
Type: String
Description:
en: The ID of the ALB instance.
zh: ALB实例的ID。
Required: true
LogProject:
Type: String
Description:
en: The name of the LogHub project.
zh: LogHub项目的名称。
Required: true
Resources:
LoadBalancerAccessLogConfigAttachment:
Type: ALIYUN::ALB::AccessLogEnable
Properties:
LogStore:
Ref: LogStore
LoadBalancerId:
Ref: LoadBalancerId
LogProject:
Ref: LogProject
{
"ROSTemplateFormatVersion": "2015-09-01",
"Parameters": {
"LogStore": {
"Type": "String",
"Description": {
"en": "The name of the LogHub logstore.",
"zh": "LogHub日志库的名称。"
},
"Required": true
},
"LoadBalancerId": {
"Type": "String",
"Description": {
"en": "The ID of the ALB instance.",
"zh": "ALB实例的ID。"
},
"Required": true
},
"LogProject": {
"Type": "String",
"Description": {
"en": "The name of the LogHub project.",
"zh": "LogHub项目的名称。"
},
"Required": true
}
},
"Resources": {
"LoadBalancerAccessLogConfigAttachment": {
"Type": "ALIYUN::ALB::AccessLogEnable",
"Properties": {
"LogStore": {
"Ref": "LogStore"
},
"LoadBalancerId": {
"Ref": "LoadBalancerId"
},
"LogProject": {
"Ref": "LogProject"
}
}
}
}
}
该文章对您有帮助吗?