Skip to content

Instantly share code, notes, and snippets.

View erlingwl's full-sized avatar

Erling Wegger Linde erlingwl

View GitHub Profile
@erlingwl
erlingwl / github.json
Created April 18, 2012 19:16
data_bags/github.json
{
"id": "github",
"fqdn": "github.com",
"rsa": "use value from cat ~/.ssh/known_hosts | grep git"
}
@erlingwl
erlingwl / webserver.rb
Created April 18, 2012 18:27
Chef webserver role
name "webserver"
description "Systems that serve HTTP"
run_list(
"recipe[chef-client]",
"recipe[ssh_known_hosts]",
"recipe[apt]",
"recipe[git]",
"recipe[nginx]",
"recipe[unicorn]"
)
@erlingwl
erlingwl / gist:2027622
Created March 13, 2012 08:40
Boostrap chef with Ruby 1.9.3
bash -c '
if [ ! -f /usr/local/bin/chef-client ]; then
apt-get update
sudo apt-get install -y build-essential zlib1g zlib1g-dev openssl libssl-dev libyaml-dev
cd /tmp
wget ftp://ftp.ruby-lang.org//pub/ruby/1.9/ruby-1.9.3-p125.tar.gz
tar xvf ruby-1.9.3-p125.tar.gz
cd ruby-1.9.3-p125
./configure
make