pandora vagrant setup
This commit is contained in:
commit
8b9f8e190b
4 changed files with 49 additions and 0 deletions
3
.bzrignore
Normal file
3
.bzrignore
Normal file
|
@ -0,0 +1,3 @@
|
|||
pandora
|
||||
pandora_install.log
|
||||
.vagrant
|
12
README
Normal file
12
README
Normal file
|
@ -0,0 +1,12 @@
|
|||
Pan.do/ra Vagrant
|
||||
|
||||
1) Install Vagrant (https://www.vagrantup.com/)
|
||||
1) Checkout this repository
|
||||
2) Setup Vagrant
|
||||
|
||||
$ vagrant up
|
||||
|
||||
3) Open Browser at http://localhost:2620/
|
||||
4) SSH into VM
|
||||
|
||||
$ vagrant ssh
|
21
Vagrantfile
vendored
Normal file
21
Vagrantfile
vendored
Normal file
|
@ -0,0 +1,21 @@
|
|||
# -*- 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|
|
||||
config.vm.hostname = 'pandora'
|
||||
config.vm.guest = :ubuntu
|
||||
config.package.name = 'pandora.box'
|
||||
config.vm.box = 'trusty-cloud'
|
||||
config.vm.box_url = 'https://cloud-images.ubuntu.com/vagrant/trusty/current/trusty-server-cloudimg-amd64-vagrant-disk1.box'
|
||||
config.vm.network "forwarded_port", guest: 80, host: 2620
|
||||
config.vm.synced_folder ".", "/srv"
|
||||
config.vm.provision "shell", path: "install.sh"
|
||||
config.vm.provision :shell, :inline => "sudo /srv/pandora/ctl start", run: "always"
|
||||
config.vm.provider "virtualbox" do |vb|
|
||||
vb.customize ["modifyvm", :id, "--memory", "1024"]
|
||||
vb.customize ['modifyvm', :id, '--cpus', '2']
|
||||
end
|
||||
end
|
13
install.sh
Executable file
13
install.sh
Executable file
|
@ -0,0 +1,13 @@
|
|||
#!/bin/bash
|
||||
if [ -x /srv/pandora ]; then
|
||||
sudo -H -u vagrant /srv/pandora/update.py dev
|
||||
else
|
||||
apt-get update -qq
|
||||
apt-get install -y curl >/dev/null 2>&1
|
||||
curl https://wiki.0x2620.org/browser/pandora/vm/pandora_install.sh?format=txt > /vagrant/pandora_install.sh 2>/dev/null
|
||||
echo "Installing pan.do/ra..."
|
||||
echo "logging installation progress into pandora_install.log"
|
||||
export PUSER=vagrant
|
||||
/vagrant/pandora_install.sh >/vagrant/pandora_install.log 2>&1
|
||||
rm /vagrant/pandora_install.sh
|
||||
fi
|
Loading…
Reference in a new issue