31 lines
617 B
Bash
31 lines
617 B
Bash
#!/bin/sh
|
|
#
|
|
# postinst script for cacert-boardvoting
|
|
#
|
|
# see: dh_installdeb(1)
|
|
|
|
set -e
|
|
|
|
case "$1" in
|
|
configure)
|
|
adduser --system --quiet --home /srv/cacert-boardvoting cacert-boardvoting
|
|
DATADIR=/srv/cacert-boardvoting/data
|
|
if [ -d "${DATADIR}" ]; then
|
|
chown -R cacert-boardvoting "${DATADIR}"
|
|
else
|
|
install -d --owner cacert-boardvoting --mode 0700 "${DATADIR}"
|
|
fi
|
|
;;
|
|
|
|
abort-upgrade|abort-remove|abort-deconfigure)
|
|
;;
|
|
|
|
*)
|
|
echo "postinst called with unknown argument \`$1'" >&2
|
|
exit 0
|
|
;;
|
|
esac
|
|
|
|
#DEBHELPER#
|
|
|
|
exit 0
|