diff --git a/.gitignore b/.gitignore index db4561ea..1e83a2d1 100644 --- a/.gitignore +++ b/.gitignore @@ -52,3 +52,5 @@ docs/_build/ # PyBuilder target/ + +.vagrant/ diff --git a/Vagrantfile b/Vagrantfile new file mode 100644 index 00000000..6e463cf5 --- /dev/null +++ b/Vagrantfile @@ -0,0 +1,24 @@ +# -*- mode: ruby -*- +# vi: set ft=ruby : + +# Vagrantfile API/syntax version. Don't touch unless you know what you're doing! +VAGRANTFILE_API_VERSION = "2" + +Vagrant.configure(VAGRANTFILE_API_VERSION) do |config| + # All Vagrant configuration is done here. The most common configuration + # options are documented and commented below. For a complete reference, + # please see the online documentation at vagrantup.com. + + config.vm.box = "ubuntu/precise32" + + # Note: if it complains about guest extension versions, you can manually install them + # because each VirtualBox installation has the capability of mounting an ISO virtual + # CD to install its guest extension from. + + # Create a forwarded port mapping which allows access to a specific port + # within the machine from a port on the host machine. + config.vm.network :forwarded_port, guest: 3306, host: 3306 + + config.vm.provision :shell, :path => "bootstrap.sh" + +end \ No newline at end of file diff --git a/bootstrap.sh b/bootstrap.sh new file mode 100644 index 00000000..38d37a11 --- /dev/null +++ b/bootstrap.sh @@ -0,0 +1,43 @@ +#!/usr/bin/env bash + +sudo apt-get update + +sudo apt-get clean + +sudo apt-get -y install libtool +sudo apt-get -y install python-dev libyaml-dev libffi-dev +sudo apt-get -y install python-pip + +cd /vagrant/ + +sudo pip install --upgrade pip +sudo ln -s /usr/local/bin/pip /usr/bin/pip 2>/dev/null + +sudo apt-get -y install libmysqlclient-dev + +sudo pip install --allow-external mysql-connector-python mysql-connector-python +sudo pip install --allow-external python-openfire python-openfire==0.2.3-beta +sudo pip install https://github.com/eve-val/evelink/zipball/master +sudo pip install --allow-external libffi-dev libffi-dev + +#TODO collect user input and use that to populate the passwords +sudo apt-get -y install mysql-server-5.5 +sudo apt-get -y install rabbitmq-server +sudo apt-get -y install python-xmpp + +sudo pip install -r requirements.txt + + +# TODO Extract the rest of this file to separate shell script + + + +## comment out bootstrap_permissions() before sync, as per instructions +#cp groupmanagement/__init__.py groupmanagement/__init__.py.bak +#sed "s/bootstrap_permissions()/#bootstrap_permissions()/" groupmanagement/__init__.py.bak > groupmanagement/__init__.py +#python manage.py syncdb +#mv groupmanagement/__init__.py.bak groupmanagement/__init__.py + +#python manage.py celeryd --verbosity=2 --loglevel=DEBUG +#python manage.py celerybeat --verbosity=2 --loglevel=DEBUG +#python manage.py runserver \ No newline at end of file diff --git a/requirements.txt b/requirements.txt new file mode 100644 index 00000000..278d06f7 --- /dev/null +++ b/requirements.txt @@ -0,0 +1,14 @@ +# Python Stuff # - see bootstrap.sh +mysql-python + +dnspython +passlib + +# Django Stuff # +django==1.6.1 +django-evolution +django-bootstrap-form +django-celery + +# Needed Apps +bcrypt \ No newline at end of file