virtual-appliance/appliances/dpaste/firstboot.start
Albert Hopkins f79cc8a353 Move appliances/configs/scripts to seperate directories.
Instead of having everything in the root directory, split them in seperate
directories (appliances, scripts, & configs).  This makes things a little
tidier.

Also added a now Makefile target, appliance-list, that prints a list of the
available appliances.  The split directory change made this easier.
2014-06-09 02:26:17 +00:00

20 lines
418 B
Bash
Executable File

#!/bin/bash
set -e
[ -e /firstboot ] || exit 0
echo 'Creating dpaste database'
createuser -U postgres -D -S -R dpaste
createdb -U postgres dpaste
. /opt/dpaste/bin/activate
PYTHON=/opt/dpaste/bin/python
PYTHONPATH=/opt/dpaste/dpaste ; export PYTHONPATH
$PYTHON /opt/dpaste/manage.py syncdb --noinput
$PYTHON /opt/dpaste/manage.py migrate --all
rc-update add dpaste default
/etc/init.d/dpaste start
rm /firstboot