debian: improving postinst

This commit is contained in:
Jérôme Schneider 2013-08-28 14:46:28 +02:00
parent 614529f5aa
commit c0be99d1a5
1 changed files with 6 additions and 9 deletions

15
debian/postinst vendored
View File

@ -31,6 +31,12 @@ case "$1" in
echo -n "Generating static files.."
su compte-agglo-montpellier -p -c "/usr/bin/compte-agglo-montpellier collectstatic --noinput --link"
echo "..done"
if [ -z "$2" ]; then
echo -n "Generating database.."
su compte-agglo-montpellier -p -c "/usr/bin/compte-agglo-montpellier syncdb --all --noinput"
su compte-agglo-montpellier -p -c "/usr/bin/compte-agglo-montpellier migrate --fake"
echo "..done"
fi
;;
@ -48,15 +54,6 @@ case "$1" in
;;
esac
case "$1" in
configure)
if [ -z "$2" ]; then
su compte-agglo-montpellier -p -c "/usr/bin/compte-agglo-montpellier syncdb --all --noinput"
su compte-agglo-montpellier -p -c "/usr/bin/compte-agglo-montpellier migrate --fake"
fi
;;
esac
# dh_installdeb will replace this with shell code automatically
# generated by other debhelper scripts.