Skip to content

Instantly share code, notes, and snippets.

@cantremember
Last active April 30, 2017 18:44
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save cantremember/91b6995bfefdcc8108c64c838e089ba6 to your computer and use it in GitHub Desktop.
Save cantremember/91b6995bfefdcc8108c64c838e089ba6 to your computer and use it in GitHub Desktop.
baseline Vagrant file for Node.js perf testing
Vagrant.configure(2) do |config|
config.vm.box = "ubuntu-i386-14.10"
# Node.js server port, per `config.app.port`
config.vm.network "forwarded_port", guest: 3201, host: 3201
# # for remote inspection using `webkit-devtools-agent` or some equivalent
# config.vm.network "forwarded_port", guest: 3999, host: 3999
config.ssh.forward_agent = true
config.vm.provision "shell", inline: <<-SHELL
sudo apt-get update
sudo apt-get install -y gcc g++
sudo apt-get install -y git
sudo apt-get install -y htop nmon
egrep -q 'vagranthost' /etc/hosts || sudo bash -c 'echo "\
# Vagrant Host
10.0.2.2 vagranthost" >> /etc/hosts'
SHELL
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment