Skip to content

Instantly share code, notes, and snippets.

@jmahowald
Created August 13, 2014 03:47
Show Gist options
  • Save jmahowald/b05fdb862b278e61086e to your computer and use it in GitHub Desktop.
Save jmahowald/b05fdb862b278e61086e to your computer and use it in GitHub Desktop.
Bootstrap chef script for centos to use chef dk instead of chef omnibus
sudo yum install wget -y
export RPM_VERSION=chefdk-0.2.0-2.el6.x86_64
export CHEF_RPM=$RPM_VERSION.rpm
if rpm -qa|grep $RPM_VERSION; then
echo "Already have chef dk installed"
else
wget --no-check-certificate https://opscode-omnibus-packages.s3.amazonaws.com/el/6/x86_64/$CHEF_RPM
sudo rpm -iU $CHEF_RPM
chef -v
rm $CHEF_RPM
echo 'export PATH=/opt/chefdk/embedded/bin:$PATH' > /etc/profile.d/chef.sh
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment