learning-unlimited/ESP-Website — pull request #1142 by pricem (2014-03-12 17:36:48+00:00)
Title: Vagrant based dev server setup

Despite repeated efforts, our system is still too difficult for a new person to set up. We need to fix this.

Last month Joel set up a deployment system using Fabric. This could be very useful as it would provide a unified framework for development and production servers, and I'll be working on this in the future. However, I want to take a step back temporarily and ask for a critical review of something less ambitious.

This is a relatively small set of changes that should allow dev servers to be created using Vagrant. The goal is to have a simplified and more Python-based approach relative to our existing setup script, and also to avoid exchanging huge VM image files.

Here's how it works ([documentation is in progress here](https://github.com/learning-unlimited/ESP-Website/blob/fabric-deployment-clean/docs/dev/vagrant.rst)):
* You check out the code and install a few software prerequisites including Vagrant and Virtualbox.
* Vagrant creates a minimalist Ubuntu VM (no GUI) on your machine. Your working copy of the code is shared with the VM, so you can edit it without SSHing to the VM.
* You run commands to "remotely" set up the software and database within the VM.
* You can remotely start/stop the VM's dev server and view the site on a browser on your machine (via port forwarding).

I've tested this on Windows but it needs testing on other platforms (I wasn't able to do this at home, because you can't create a VM inside a VM with Virtualbox).

Please help make this procedure as streamlined as robust as possible, even if it involves pointing out mistakes and recommending redesign work.