Adoptable Cookbooks List

Looking for a cookbook to adopt? You can now see a list of cookbooks available for adoption!
List of Adoptable Cookbooks

Supermarket Belongs to the Community

Supermarket belongs to the community. While Chef has the responsibility to keep it running and be stewards of its functionality, what it does and how it works is driven by the community. The chef/supermarket repository will continue to be where development of the Supermarket application takes place. Come be part of shaping the direction of Supermarket by opening issues and pull requests or by joining us on the Chef Mailing List.

Select Badges

Select Supported Platforms


aws-cloudwatchlogs (7) Versions 1.1.1

Install and Configure AWS CloudWatch Logs Agent

cookbook 'aws-cloudwatchlogs', '= 1.1.1'
cookbook 'aws-cloudwatchlogs', '= 1.1.1', :supermarket
knife supermarket install aws-cloudwatchlogs
knife supermarket download aws-cloudwatchlogs
Quality 50%

AWS CloudWatch Logs Cookbook

Runtime License

Unofficial Chef Cookbook that installs AWS CloudWatch Logs<sup>™</sup> Agent and deploy it's configurations automatically.


Add this cookbook to your base recipe: ruby cookbook 'aws-cloudwatchlogs', '~> 1.1.1'

You need to configure the following node attributes via an environment or role: ruby default_attributes( 'aws-cwlogs' => { 'region' => 'your_aws_region', 'aws_access_key_id' => 'your_aws_access_key', 'aws_secret_access_key' => 'your_aws_secret_key', 'log_files' => { '/var/log/syslog' => { 'datetime_format' => '%b %d %H:%M:%S', 'file' => '/var/log/syslog', 'buffer_duration' => '5000', 'log_stream_name' => '{instance_id}', 'initial_position' => 'start_of_file', 'log_group_name' => '/var/log/syslog' } } } )

Or you can also configure by declaring it in another cookbook at a higher precedence level: ruby default['aws-cwlogs']['region'] = 'your_aws_region' default['aws-cwlogs']['aws_access_key_id'] = 'your_aws_access_key' default['aws-cwlogs']['aws_secret_access_key'] = 'your_aws_secret_key' default['aws-cwlogs']['log_files']['/var/log/syslog'] = { 'datetime_format' => '%b %d %H:%M:%S', 'file' => '/var/log/syslog', 'buffer_duration' => '5000', 'log_stream_name' => '{instance_id}', 'initial_position' => 'start_of_file', 'log_group_name' => '/var/log/syslog' }

Remember: You can configure as many logs as you need with log_files attribute.

Note: We are not making use of data_bags for AWS Credentials in this recipe at this time.


Those attributes used before will generate the AWS CloudWatch Logs configuration below:

datetime_format = %b %d %H:%M:%S
file = /var/log/syslog
buffer_duration = 5000
log_stream_name = {instance_id}
initial_position = start_of_file
log_group_name = /var/log/syslog

For more deployment details about AWS CloudWatch Logs, please visit the AWS CloudWatch Logs Documentation.



  • Ubuntu 14.04


See attributes/default.rb for default values.



This recipe will check if all necessary requirements being met, and after that will call configure and install recipe.


This recipe will prepare and configure all files required by AWS CloudWatch Logs.


This recipe will install AWS CloudWatch Logs Agent.


See for more details.

License and Author

See LICENSE for more details.


Amazon Web Services and AWS are trademarks of, Inc. or its affiliates in the United States and/or other countries.

Dependent cookbooks

This cookbook has no specified dependencies.

Contingent cookbooks

There are no cookbooks that are contingent upon this one.


1.1.1 / 2016-10-24

  • Initial version of aws-cloudwatchlogs cookbook.

Collaborator Number Metric

1.1.1 failed this metric

Failure: Cookbook has 0 collaborators. A cookbook must have at least 2 collaborators to pass this metric.

Foodcritic Metric

1.1.1 passed this metric