.ebextensions/eb-logs.config
##################################################################
## Sets up the elastic beanstalk log publication to include
## the admin logs for cloudwatch logs
##################################################################
Resources:
AWSEBAutoScalingGroup:
Metadata:
"AWS::CloudFormation::Init":
configSets:
"_OnInstanceBoot":
"CmpFn::Insert":
values:
- EBCWLLogPublicationSetup
EBCWLLogPublicationSetup:
files:
"/opt/elasticbeanstalk/tasks/taillogs.d/cwl-system.conf":
content: |
/var/log/awslogs-agent-setup.log
/var/log/awslogs.log
/var/log/eb-cwlogs.log
mode : "000644"
"/opt/elasticbeanstalk/tasks/bundlelogs.d/cwl-system.conf":
content: |
/var/log/awslogs-agent-setup.log
/var/log/awslogs.log
/var/log/eb-cwlogs.log
mode : "000644"
"/opt/elasticbeanstalk/tasks/systemtaillogs.d/cwl-system.conf":
content: |
/var/log/awslogs-agent-setup.log
/var/log/awslogs.log
/var/log/eb-cwlogs.log
mode : "000644"
"/opt/elasticbeanstalk/tasks/publishlogs.d/cwl-system.conf":
content: |
/var/log/awslogs-agent-setup.log ## this isn't rotated
/var/log/awslogs.log*.gz
mode : "000644"