update vm build. use title for new lists not id, also make first user admin
This commit is contained in:
parent
956854d5bc
commit
0eeb3e223d
8 changed files with 35 additions and 29 deletions
|
|
@ -2,13 +2,9 @@ Create virtual disk of pan.do/ra
|
|||
|
||||
== ubuntu-vm-builder setup ==
|
||||
|
||||
due to https://bugs.launchpad.net/ubuntu/+source/vm-builder/+bug/676132
|
||||
we need to use maverick-proposed repository:
|
||||
|
||||
echo "deb http://archive.ubuntu.com/ubuntu/ maverick-proposed restricted main multiverse universe" > /etc/apt/sources.list.d/ubunt-proposed.list
|
||||
apt-get update
|
||||
apt-get -t maverick-proposed install ubuntu-vm-builder
|
||||
on ubuntu 11.10 you need to install python-vm-builder
|
||||
|
||||
apt-get install python-vm-builder
|
||||
|
||||
due to https://bugs.launchpad.net/vmbuilder/+bug/683614
|
||||
building vbox images does not work. install virtualbox_vm.py:
|
||||
|
|
@ -43,9 +39,7 @@ Pan.do/ra is installed in /srv/pandora and is served with nginx on http://pandor
|
|||
== Update ==
|
||||
to get the latest version of pan.do/ra
|
||||
cd /srv/pandora
|
||||
bzr pull
|
||||
cd static/oxjs
|
||||
bzr pull
|
||||
./update.sh
|
||||
|
||||
you might have to adjust the database at this point. now restart pandora daemons
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
#!/bin/sh
|
||||
base=$(pwd)
|
||||
sudo vmbuilder vbox ubuntu --suite=maverick \
|
||||
sudo vmbuilder vbox ubuntu --suite=oneiric \
|
||||
--verbose --debug \
|
||||
--arch i386 \
|
||||
--dest $base/pandora \
|
||||
|
|
@ -11,7 +11,6 @@ sudo vmbuilder vbox ubuntu --suite=maverick \
|
|||
--pass pandora \
|
||||
--components main,universe,multiverse \
|
||||
--ppa j/pandora \
|
||||
--ppa gstreamer-developers/ppa \
|
||||
--addpkg openssh-server \
|
||||
--addpkg acpid \
|
||||
--addpkg vim \
|
||||
|
|
@ -33,8 +32,6 @@ sudo vmbuilder vbox ubuntu --suite=maverick \
|
|||
--addpkg python-numpy \
|
||||
--addpkg python-psycopg2 \
|
||||
--addpkg python-simplejson \
|
||||
--addpkg python-transmissionrpc \
|
||||
--addpkg transmission-daemon \
|
||||
--addpkg oxtimeline \
|
||||
--addpkg oxframe \
|
||||
--addpkg mkvtoolnix \
|
||||
|
|
|
|||
|
|
@ -12,11 +12,7 @@ chmod 755 /usr/local/bin/ffmpeg2theora
|
|||
#postgresql
|
||||
apt-get -y install postgresql
|
||||
sudo -u postgres createuser -S -D -R pandora
|
||||
sudo -u postgres createdb -O pandora pandora
|
||||
|
||||
#do not start systemwide transmission-daemon
|
||||
/etc/init.d/transmission-daemon stop
|
||||
sed -i "s/ENABLE_DAEMON=1/ENABLE_DAEMON=0/g" /etc/default/transmission-daemon
|
||||
sudo -u postgres createdb -T template0 --locale=C --encoding=UTF8 -O pandora pandora
|
||||
|
||||
#rabbitmq
|
||||
RABBITPWD=$(pwgen -n 16 -1)
|
||||
|
|
@ -26,11 +22,16 @@ rabbitmqctl set_permissions -p /pandora pandora ".*" ".*" ".*"
|
|||
|
||||
#pandora
|
||||
cat > /srv/pandora/pandora/local_settings.py << EOF
|
||||
DATABASE_ENGINE = 'postgresql_psycopg2'
|
||||
DATABASE_NAME = 'pandora'
|
||||
DATABASE_USER = 'pandora'
|
||||
DATABASES = {
|
||||
'default': {
|
||||
'NAME': 'pandora',
|
||||
'ENGINE': 'django.db.backends.postgresql_psycopg2',
|
||||
'USER': 'pandora',
|
||||
'PASSWORD': '',
|
||||
}
|
||||
}
|
||||
|
||||
POSTER_SERVICES=['http://data.0xdb.org/poster/']
|
||||
DATA_SERVICE='http://data.0xdb.org/api/'
|
||||
|
||||
BROKER_PASSWORD = "$RABBITPWD"
|
||||
|
||||
|
|
@ -41,6 +42,8 @@ cd /srv/pandora/pandora
|
|||
sudo -u pandora python manage.py syncdb --noinput
|
||||
echo "UPDATE django_site SET domain = 'pandora.local', name = 'pandora.local' WHERE 1=1;" | sudo -u pandora python manage.py dbshell
|
||||
|
||||
sudo -u pandora python manage.py update_static
|
||||
|
||||
mkdir /srv/pandora/data
|
||||
chown -R pandora:pandora /srv/pandora
|
||||
|
||||
|
|
@ -51,6 +54,6 @@ service pandora-tasks start
|
|||
service pandora start
|
||||
|
||||
#nginx
|
||||
sed "s/__PREFIX__/\/srv\/pandora/g" "/srv/pandora/nginx/vhost.in" > "/etc/nginx/sites-available/default"
|
||||
sed "s/__PREFIX__/\/srv\/pandora/g" "/srv/pandora/etc/nginx/vhost.in" > "/etc/nginx/sites-available/default"
|
||||
service nginx restart
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue