Sha256: 939860f145189c8a09cb87fd121dceaa9c18f7684655a2df51920786a47f793d

Contents?: true

Size: 1.27 KB

Versions: 4

Compression:

Stored size: 1.27 KB

Contents

bash -c '
if [ ! -f /usr/bin/chef-client ]; then
  rpm -Uvh http://download.fedora.redhat.com/pub/epel/5/i386/epel-release-5-4.noarch.rpm
  rpm -Uvh http://download.elff.bravenet.com/5/i386/elff-release-5-3.noarch.rpm

  yum install -y ruby ruby-devel gcc gcc-c++ automake autoconf make

  cd /tmp
  wget http://production.cf.rubygems.org/rubygems/rubygems-1.3.7.tgz
  tar zxf rubygems-1.3.7.tgz
  cd rubygems-1.3.7
  ruby setup.rb --no-format-executable
fi

gem update --system
gem update
gem install ohai --no-rdoc --no-ri --verbose
gem install chef --no-rdoc --no-ri --verbose <%= bootstrap_version_string(:gems) %>

mkdir -p /etc/chef

(
cat <<'EOP'
<%= IO.read(Chef::Config[:validation_key]) %>
EOP
) > /tmp/validation.pem
awk NF /tmp/validation.pem > /etc/chef/validation.pem
rm /tmp/validation.pem

(
cat <<'EOP'
log_level        :info
log_location     STDOUT
chef_server_url  "<%= Chef::Config[:chef_server_url] %>"
validation_client_name "<%= Chef::Config[:validation_client_name] %>"
<% if @config[:chef_node_name] == nil %>
# Using default node name (fqdn)
<% else %>
node_name "<%= @config[:chef_node_name] %>"
<% end %>
EOP
) > /etc/chef/client.rb

(
cat <<'EOP'
<%= { "run_list" => @run_list }.to_json %>
EOP
) > /etc/chef/first-boot.json

/usr/bin/chef-client -j /etc/chef/first-boot.json'

Version data entries

4 entries across 4 versions & 2 rubygems

Version Path
chef-0.9.18 lib/chef/knife/bootstrap/centos5-gems.erb
rmm-chef-0.10.0.rc.0 lib/chef/knife/bootstrap/centos5-gems.erb
chef-0.10.0.rc.0 lib/chef/knife/bootstrap/centos5-gems.erb
chef-0.9.16 lib/chef/knife/bootstrap/centos5-gems.erb