Skip to content

Instantly share code, notes, and snippets.

@rightson
Last active April 21, 2017 04:54
Show Gist options
  • Save rightson/8449e72659304168076746b1b5e868a7 to your computer and use it in GitHub Desktop.
Save rightson/8449e72659304168076746b1b5e868a7 to your computer and use it in GitHub Desktop.
my Vagrantfile for centos-6.7 box
# -*- mode: ruby -*-
# vi: set ft=ruby :
Vagrant.configure("2") do |config|
config.putty.modal = true
config.vm.box = "bento/centos-6.7"
config.vm.provision "shell", inline: <<-SHELL
yum update -y
yum install -y epel-release
yum install -y http://opensource.wandisco.com/centos/6/git/x86_64/wandisco-git-release-6-1.noarch.rpm
yum install -y git vim
curl https://raw.githubusercontent.com/creationix/nvm/v0.23.3/install.sh | bash
echo "source /home/vagrant/.nvm/nvm.sh" >> /home/vagrant/.bashrc
source /home/vagrant/.bashrc
nvm install stable
nvm alias default stable
npm -g install yarn
yarn global add nodemon pm2 mocha jsonlint
wget https://storage.googleapis.com/golang/go1.8.1.linux-amd64.tar.gz -P /tmp
tar zxvf /tmp/go1.8.1.linux-amd64.tar.gz -C /usr/local
ln -s ../go/bin/go /usr/local/bin/go
echo "export PATH=\$PATH:$(go env GOPATH)/bin" >> /home/vagrant/.bashrc
SHELL
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment