On this page:
  • Setting up virtual machines with Vagrant

Setting up virtual machines with Vagrant

I spent a week focusing on system administration, and I feel more comfortable with my setup already. My web server hosts a number of blogs (like this one!) as well as my QuantifiedAwesome.com tracking dashboard. I want to make sure that things are backed up and that I can verify that my backups are running by creating a working website. It’s also useful to have a separate development environment where I can try out server configuration changes before applying them to production. Virtual machines to the rescue!

Vagrant is a tool that makes it easy to create and manage virtual machines with forwarded ports and shared folders. I use it for a couple of Ubuntu-based virtual machines on my laptop, and another backup-focused virtual machine on our Ubuntu desktop.

2013-10-28 Setting up virtual machines with Vagrant

You can make your Vagrant box more secure by changing the default passwords for root and vagrant, and setting up your own SSH key. Use vagrant package and vagrant box add to make this a new base box.

Related tools:

  • Give Veewee kernel and install info, and it will make base boxes for you. Good for testing different versions of distributions.
  • Vagrant works with Chef, Puppet, or shell scripts for provisioning. Need to reverse-engineer config from an existing server? Check out Devstructure Blueprint.
  • If you upgrade kernels or Virtualbox/VMWare, you might find vagrant-vbguest handy.
  • If your host system is pretty much the same as your deployment system architecture, check out Docker for a lighter-weight way to isolate your development environment.

These are some of my notes from when I was setting up my VMs. Different console backgrounds in Putty really help!

2013-10-28 Setting up my development environment VMs


2013-10-28 Deployment procedures