Vagrant is terrific. It makes the process of launching headless linux environment easier and reproducible for testing software packages. I am using Vagrant with Oracle VM VirtualBox. To use Vagrant, create a new folder and put
Vagrantfile in it, then run
vagrant up to boot up the box.
Vagrantfile is customizable for variety of purposes. Vagrant can automatically generate a
vagrant init command. Visit Atlas to find more choices of available box.
This Vagrantfile requires
bento/ubuntu16.04 box. This box (OS image) can be obtained with
vagrant box add bento/ubuntu-16.04.
# -*- mode: ruby -*- # vi: set ft=ruby : Vagrant.configure(2) do |config| config.vm.box = "bento/ubuntu-16.04" config.vm.hostname = "server1" config.vm.network "public_network" config.vm.provider "virtualbox" do |vb| vb.memory = "512" end end
- This box is allocated with 512 MB memory, as indicated with
- The Vagrant will set this up with bridged network (not behind NAT) so that I will have its own private IP address accessible by machines in the same network.
- Change the