Installing Chef Client

DATED, DON'T USE

Warning: currently chef-client startup works, but due to a yet unresolved bug (pid file being wiped at_exit) shutdown is broken.

1. Install the ELFF repository.

2. This is the big one, it should bring down the multitude of dependencies

yum install rubygem-chef

3. Edit /etc/chef/client.rb to reflect your servers hostname.

4. Boot safe it, fire it up and give it a try.

chkconfig chef-client on

service chef-client start

chef-client

5. Oops, 401 unauthorized. We can fix this by opening the server web interface (see the server install section) and validating the registration. You'll need to be logged in to see this option.

6. Hopefully you have your chef-server setup and a simple cookbook created, say one called 'helloworld'. Let's subscribe the client to this cookbook. This triggers a chef run as well.

 

echo '{
  "recipes": [
   "helloworld"
  ]
} ' > add_recipes

chef-client -j add_recipes