/chef-client-cookbook

Chef cookbook to setup chef-client as a periodic cron job.

Primary LanguageRuby

chef_client Cookbook

Chef cookbook to setup chef-client as a periodic cron job.

Requirements

Attributes

chef_client::default

Key Type Description Default
['chef_client']['bin'] String The chef-client executable to be run by the cron job /usr/local/bin/chef-client
['chef_client']['sleep_time'] Integer Seconds to sleep before running chef-client. If nil it will be a random value nil
['chef_client']['log_dir'] String Directory where the chef-client log will be stored /var/log/chef-client
['chef_client']['log_file'] String The chef-client log path. By default relative to the log_dir attribute value /var/log/chef-client/chef-client.log
['chef_client']['cron']['minute'] String The minute argument for the cron job */30
['chef_client']['cron']['hour'] String The hour argument for the cron job *

Usage

chef_client::default

Just include chef_client in your node's run_list:

{
  "name":"my_node",
  "run_list": [
    "recipe[chef_client]"
  ]
}