Skip to content

Instantly share code, notes, and snippets.

@just3ws
Forked from ryanb/chef_solo_bootstrap.sh
Last active December 15, 2015 01:58
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save just3ws/5183471 to your computer and use it in GitHub Desktop.
Save just3ws/5183471 to your computer and use it in GitHub Desktop.
#!/usr/bin/env bash -x
apt-get -y update
# -------------------------------
# Based on bootstrap-ubuntu-12-04
# https://raw.github.com/fesplugas/rbenv-bootstrap/master/bin/rbenv-bootstrap-ubuntu-12-04
# Update sources:
apt-get -y update
# Install development tools:
apt-get -y install build-essential
# Packages required for compilation of some stdlib modules
apt-get -y install tklib
# Extras for RubyGems and Rails:
apt-get -y install zlib1g-dev libssl-dev
# Readline Dev on Ubuntu 10.04 LTS:
# sudo apt-get -y install libreadline5-dev
# Readline Dev on Ubuntu 12.04 LTS:
apt-get -y install libreadline-gplv2-dev
# Install some nokogiri dependencies:
apt-get -y install libxml2 libxml2-dev libxslt1-dev
# -------------------------------
apt-get -y install libyaml-dev libffi-dev libgdbm-dev
apt-get -y dist-upgrade
cd /tmp
wget ftp://ftp.ruby-lang.org/pub/ruby/1.9/ruby-1.9.3-p392.tar.gz
tar -xvzf ruby-1.9.3-p392.tar.gz
cd ruby-1.9.3-p392/
./configure --prefix=/usr/local
make
make install
gem install chef ruby-shadow --no-ri --no-rdoc
mkdir -p /var/chef
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment