33 lines
755 B
Bash
33 lines
755 B
Bash
#!/bin/sh
|
|
# postrm script for portail-citoyen
|
|
#
|
|
# see: dh_installdeb(1)
|
|
|
|
set -e
|
|
|
|
case "$1" in purge)
|
|
deluser --quiet --system portail-citoyen > /dev/null || true
|
|
rm -f /etc/portail-citoyen/secret
|
|
rm -rf /var/lib/portail-citoyen/static/*
|
|
# source debconf stuff
|
|
. /usr/share/debconf/confmodule
|
|
# source dbconfig-common shell library, and call the hook function
|
|
if [ -f /usr/share/dbconfig-common/dpkg/postrm.pgsql ]; then
|
|
. /usr/share/dbconfig-common/dpkg/postrm.pgsql
|
|
dbc_go portail-citoyen $@
|
|
fi
|
|
|
|
DBCONF=/etc/portail-citoyen/db.conf
|
|
if [ "$1" = "purge" ]; then
|
|
rm -f $DBCONF
|
|
if which ucf >/dev/null 2>&1; then
|
|
ucf --purge $DBCONF
|
|
fi
|
|
fi
|
|
;;
|
|
|
|
esac
|
|
|
|
exit 0
|
|
|