Skip to content

Commit 95a0fff

Browse files
committed
Merge revamped Vagrantfile.
(Git is hard.)
1 parent 252c858 commit 95a0fff

File tree

3 files changed

+27
-33
lines changed

3 files changed

+27
-33
lines changed

vagrant/.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
__pycache__
2+
*.pyc
3+
.vagrant

vagrant/Vagrantfile

Lines changed: 24 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,31 @@
11
# -*- mode: ruby -*-
22
# vi: set ft=ruby :
33

4-
VAGRANTFILE_API_VERSION = "2"
5-
6-
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
7-
config.vm.provision "shell", path: "pg_config.sh"
8-
config.vm.box = "ubuntu/trusty32"
4+
Vagrant.configure("2") do |config|
5+
config.vm.box = "ubuntu/xenial32"
96
config.vm.network "forwarded_port", guest: 8000, host: 8000
107
config.vm.network "forwarded_port", guest: 8080, host: 8080
118
config.vm.network "forwarded_port", guest: 5000, host: 5000
9+
config.vm.provision "shell", inline: <<-SHELL
10+
apt-get update
11+
apt-get upgrade
12+
apt-get -qqy install make python3-pip
13+
apt-get -qqy install postgresql
14+
pip3 install --upgrade pip
15+
pip3 install flask packaging oauth2client redis passlib flask-httpauth
16+
pip3 install sqlalchemy flask-sqlalchemy psycopg2 bleach
17+
su postgres -c 'createuser -dRS ubuntu'
18+
su ubuntu -c 'createdb'
19+
su ubuntu -c 'createdb forum'
20+
su ubuntu -c 'psql forum -f /vagrant/forum/forum.sql'
21+
22+
vagrantTip="The shared directory is located at /vagrant\\nTo access your shared files: cd /vagrant"
23+
echo -e $vagrantTip > /etc/motd
24+
25+
wget http://download.redis.io/redis-stable.tar.gz
26+
tar xvzf redis-stable.tar.gz
27+
cd redis-stable
28+
make
29+
make install
30+
SHELL
1231
end

vagrant/pg_config.sh

Lines changed: 0 additions & 28 deletions
This file was deleted.

0 commit comments

Comments
 (0)