User Tools

Site Tools


Sidebar


guides:opscode_chef:install_mac_os_x

Opscode Chef : Install on Mac OS X

1. update macports

Update macports first. (install macports by installing Xcode from your Mac OS X Install DVD)

sudo port -v selfupdate

Update all old ports

sudo port upgrade outdated

2. update RubyGems

sudo gem update --system

3. install chef

sudo gem install chef

4. check JSON 1.4.3 gem issue

sudo gem uninstall -aIx json
sudo gem install -v1.4.2 json

5. create chef repo

cd ~
git clone git://github.com/opscode/chef-repo.git

6. create .chef dir

mkdir -p ~/chef-repo/.chef

7. setup your local repo with your chef-server keys and knife configuration

cp USERNAME.pem ~/chef-repo/.chef
cp ORGANIZATION-validator.pem ~/chef-repo/.chef
cp knife.rb ~/chef-repo/.chef

8. test your connection to chef-server

cd ~/chef-repo
knife client list
[
  "ORGANIZATION-validator"
]

9. setup your mac as chef-client

create chef-client configs

cd ~/chef-repo
knife configure client ./client-config

copy chef-client configs to dir /etc/chef

sudo cp -r ~/chef-repo/client-config /etc/chef

run chef for the first time to create client keys

sudo chef-client

verify your mac is saved as a chef-client (node) on the chef-server

knife node list

References:

http://wiki.opscode.com/display/chef/Installation

http://wiki.opscode.com/display/chef/Quick+Start#QuickStart-InstallChef

guides/opscode_chef/install_mac_os_x.txt · Last modified: 2010/08/14 11:09 by michaelc