Created
January 14, 2016 00:32
-
-
Save AaronGhent/729cbd3936ecdac8d5ed to your computer and use it in GitHub Desktop.
Virtual Machine for NodeJS
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
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
VAGRANTFILE_API_VERSION = "2" | |
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config| | |
config.vm.box = "ubuntu/trusty64" | |
config.vm.hostname = "nodejs" | |
config.vm.network :forwarded_port, guest: 3000, host: 3000 | |
config.vm.synced_folder "./", "/home/vagrant/srv", create: true, group: "vagrant", owner: "vagrant" | |
config.vm.provider "virtualbox" do |v| | |
v.customize ["modifyvm", :id, "--natdnshostresolver1", "on"] | |
end | |
config.vm.provision "shell", inline: <<-SHELL | |
echo ":: >><<>><<>><<>><<>><<>><<>><<>><<>><<>><< ::" | |
echo "Installing System (Patience Please)" | |
echo ":: >><<>><<>><<>><<>><<>><<>><<>><<>><<>><< ::" | |
sudo apt-get -qq update | |
sudo apt-get -qq -y install build-essential nodejs npm nodejs-legacy | |
SHELL | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment