pmtischler/auvsi_suas_competition — pull request #1 by prattmic (2014-09-26 00:57:35+00:00)
Title: Provide Vagrantfile for automated setup

This adds a Vagrantfile to support automated setup of an SUAS server with [Vagrant](https://www.vagrantup.com/).

This allows users to simply run `vagrant up` and wait while Vagrant downloads a base VM, and runs the Puppet manifest to completely prepare the machine to run the SUAS server software. This makes development and testing much more convenient, quickly allowing the server to be created and destroyed without any manual interaction.

To support this, a few changes needed to be made to the Puppet manifest.

1. `apt-get update` is run before the rest of the manifest. This is necessary because the base image's apt cache is very old, and Puppet will otherwise quickly fail when apt tries to install old versions of software. This will also be advantageous for a manual install, should Puppet be used to update the software, as the cache may easily be outdated.

2. A class is added, using the `apt` Puppet module, to ensure that the main, restricted, universe, and multiverse repos are all available and enabled. The Ubuntu base image (and I believe any Ubuntu server installation) comes without the multiverse repo enabled. `libapache2-mod-fastcgi` comes from multiverse, so its addition is necessary for the `apache` class to complete successfully.

3. Google Chrome is installed directly from Google's repo, rather than the .deb. I'm not sure how this worked before, as directly attempting the .deb is expected to fail with missing dependencies, which can be resolved with `apt-get -f install`, after which a second `dpkg` invocation would succeed. Nevertheless, installing directly from the repository resolves the issue.

The `setup.sh` script has been updated to reflect the changes for Vagrant, most notably installing the `apt` Puppet module. However, I have only used Vagrant to bring up one of these machines, so I have not actually run the updated script to ensure that it is correct.

I updated a couple of the READMEs with additional instructions for using Vagrant, as well as running the Django app listening on all addresses, so the server can be accessed outside the VM. Vagrant forwards port 8080 from the guest to the host, making the server available on the host's port 8080.

On a mostly unrelated note, the Puppet manifest seems to include a lot of software that is not necessary simply to run a Django server, such as Chrome, Eclipse, Qt, TeX Live, etc. Would you mind if I submit a pull request removing a lot of that? With so much extra software, the Puppet manifest takes nearly an hour to complete.