Created
February 27, 2011 22:58
-
-
Save ramarnat/846660 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| export PATH=/sbin:/usr/sbin:$PATH | |
| export HOME=/root | |
| cd $HOME | |
| yum install -q -y ruby ruby-devel gcc gcc-c++ automake autoconf make | |
| yum install -q -y unixODBC unixODBC-devel | |
| gem install ohai chef --no-rdoc --no-ri --verbose | |
| gem install right_aws --no-rdoc --no-ri --verbose | |
| gem install ruby-odbc --no-rdoc --no-ri --verbose | |
| gem install dbd-odbc --no-rdoc --no-ri --verbose | |
| gem install fastercsv --no-rdoc --no-ri --verbose | |
| 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 :debug | |
| log_location '/var/log/chef-client.log' | |
| chef_server_url "<%= Chef::Config[:chef_server_url] %>" | |
| validation_client_name "<%= Chef::Config[:validation_client_name] %>" | |
| <% if Chef::Config[:chef_node_name] == nil %> | |
| # Using default node name" | |
| <% else %> | |
| node_name "<%= Chef::Config[:chef_node_name] %>" | |
| <% end %> | |
| EOP | |
| ) > /etc/chef/client.rb |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment