-
-
Save hiremaga/1293973 to your computer and use it in GitHub Desktop.
How I (will eventually) bootstrap my Macbook Air
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
#!/usr/bin/env sh | |
#After forking and editing YOUR_ORG to point at the right repo can be run via: | |
#bash <(curl -s https://raw.github.com/gist/1293973) | |
#if you use `curl xxx | sh` input will be messed up and there will be no pauses | |
#I keep XCode and gcc on a thumbdrive along with java, for speeding things up | |
#http://support.apple.com/downloads/DL1421/en_US/JavaForMacOSX10.7.dmg | |
read -p "Install XCode or gcc (http://github.com/kennethreitz/osx-gcc-installer)" | |
#setup your ssh keys for github | |
echo "Please enter your email: " | |
read email | |
ssh-keygen -t rsa -C "$email" | |
cat ~/.ssh/id_rsa.pub | |
cat ~/.ssh/id_rsa.pub | pbcopy | |
read -p "\n\nYour ssh public key has been copied to your clipboard. Add it to github and press any key to continue" | |
#install homebrew to get latest git. This way it still works if you did gcc, not just XCode | |
/usr/bin/ruby -e "$(curl -fsSL https://raw.github.com/gist/323731)" | |
brew install git | |
#Do a tmp version of your chef recipes. If you you pivotal_workstation:git_projects, you'll end up with the final version in ~/workspace/chef-opts, if you add it to the list | |
#obviously edit the git path to be your workstation chef cookbook repo | |
#see https://github.com/cloud-city-development/ccd_workstation for some example recipes setup. | |
cd /tmp | |
git clone [email protected]:hiremaga/workstation.git | |
cd workstation | |
#Your main chef repo should have pivotal and cdd_workstation as submodules and a valid soloistrc file | |
git submodule update --init | |
sudo gem install bundler | |
bundle install --binstubs | |
#https://github.com/mkocher/soloist is a thin wrapper for chef-solo that makes it easy to run and specify a list of recipes/ | |
#Good for workstation usage | |
bin/soloist | |
#Make sure that bundler and the required gems are installed. May still need a bundle on next use from ~/workstation/chef-opts | |
bash .rvmrc | |
gem install bundler | |
bundle |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment