Created
May 24, 2016 18:00
-
-
Save richrdkng/ec34625933ad0ef7cca3711a69b28235 to your computer and use it in GitHub Desktop.
Vagrant VM configuration for jsdoc2md/dmd
This file contains 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
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
Vagrant.configure(2) do |config| | |
config.vm.box = "hashicorp/precise64" | |
config.vm.provision :shell, :path => "vagrant/provision.sh" | |
config.vm.provision "shell", inline: <<-SHELL | |
# enter permanent su | |
sudo su | |
# update before provisioning | |
apt-get update -y | |
# install essentials | |
apt-get install -y python-software-properties | |
apt-get install -y build-essential git nano curl mc | |
# update after essentials (especially python-software-properties) | |
apt-get update -y | |
# update git | |
add-apt-repository -y ppa:git-core/ppa | |
apt-get -y install git | |
# install node & update npm | |
curl -sL https://deb.nodesource.com/setup_5.x | sudo -E bash - | |
apt-get install -y nodejs | |
npm install npm -g | |
# install gulp | |
npm rm --global gulp | |
npm install --global gulp gulp-cli | |
# install project dependencies | |
# when running Vagrant under Windows, in case of "EPROTO: protocol error, symlink...", | |
# use npm with "--no-bin-links" | |
npm install | |
# npm install --no-bin-links | |
# install tape globally to run the tests (e.g.: "npm run test") | |
npm install --global tape | |
# add custom .bashrc content to .bashrc | |
cat > /home/vagrant/.bashrc <<- EOM | |
# navigate to vagrant folder upon login | |
cd /vagrant | |
EOM | |
# update after provisioning | |
apt-get update -y | |
SHELL | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment