Skip to content

Instantly share code, notes, and snippets.

@mopx
Forked from laserlemon/Rails 3 Environment
Created May 1, 2011 00:37
Show Gist options
  • Save mopx/950136 to your computer and use it in GitHub Desktop.
Save mopx/950136 to your computer and use it in GitHub Desktop.
Snow Leopard, Homebrew, Git, RVM, Ruby, Rails, Passenger, Apache, MySQL, Memcached and ImageMagick
# 2010-10-01
#
# Mac OS X 10.6.3
# Homebrew 0.7
# Xcode 3.2.4
# Git 1.7.3.1
# RVM 1.0.12
# Ruby 1.9.2, 1.8.7
# Rails 3.0.0
# Passenger 3.0.0.pre4
# MySQL 5.1.49
# Memcached 1.4.5
# ImageMagick 6.6.4-5
# Install Snow Leopard.
# Dotfiles
echo "$(curl -fsS http://gist.github.com/raw/606100/.profile)" > ~/.profile
echo "$(curl -fsS http://gist.github.com/raw/606087/.bashrc)" > ~/.bashrc
echo "$(curl -fsS http://gist.github.com/raw/606102/.bash_profile)" > ~/.bash_profile
echo "$(curl -fsS http://gist.github.com/raw/606107/.gitignore)" > ~/.gitignore
echo "$(curl -fsS http://gist.github.com/raw/606105/.rvmrc)" > ~/.rvmrc
# Close Terminal window.
# Homebrew
ruby -e "$(curl -fsS http://gist.github.com/raw/323731/install_homebrew.rb)"
# Xcode
# Download Xcode from developer.apple.com because the version on the DVD is
# buggy and doesn't agree with RVM. It's a 3 GB download, so take a break or
# set up some of your personal interface preferences.
# Software Update
# You'll have to do it a few times to get back up to speed.
# Git
brew install git
brew update
brew upgrade
# RVM
bash < <( curl http://rvm.beginrescueend.com/releases/rvm-install-head )
rvm install 1.8.7
rvm install 1.9.2
rvm 1.9.2 --default
# Rails
gem install rails
# Passenger
gem install passenger --pre
passenger-install-apache2-module
# Follow instructions.
sudo apachectl restart
# MySQL
brew install mysql
mysql_install_db
cp /usr/local/Cellar/mysql/5.1.49/com.mysql.mysqld.plist ~/Library/LaunchAgents
mysql.server start
mysql_secure_installation
# Follow instructions.
# Memcached
brew install memcached
cp /usr/local/Cellar/memcached/1.4.5/com.danga.memcached.plist ~/Library/LaunchAgents
# ImageMagick
brew install imagemagick
# Reboot.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment