首页 > 解决方案 > 如何使用 cloudformation 模板为 Elastic Beanstalk 启用 CloudWatch

问题描述

我想将我的 AWS Cloud Formation 模板配置为使用 CloudWatch 进行日志流式传输。如何在 CloudFormation 中做到这一点?

标签: amazon-web-servicesamazon-elastic-beanstalkamazon-cloudformation

解决方案


您需要AWS::Logs::LogStream在 Cloud Formation 模板中使用资源。例如,在 YAML 格式中:

Type: AWS::Logs::LogStream
Properties: 
  LogGroupName: String
  LogStreamName: String

更多信息在官方文档页面


推荐阅读