postinst is in twms 0.05t-2.
This file is a maintainer script. It is executed when installing (*inst) or removing (*rm) the package.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 | #!/bin/sh
# postinst script for twms
set -e
if [ "$1" = "configure" ]; then
if ! getent passwd twms > /dev/null ; then
echo 'Adding system-user for twms' 1>&2
adduser --system --group --quiet --home /var/cache/twms \
--no-create-home --disabled-login twms
fi
install -d -otwms -gtwms -m2750 /var/log/twms
install -d -otwms -gtwms -m750 /var/cache/twms /var/cache/twms/tiles /var/cache/twms/traces
fi
# Automatically added by dh_python2:
if which pycompile >/dev/null 2>&1; then
pycompile -p twms /usr/share/twms -V 2.5-
fi
# End automatically added section
# Automatically added by dh_installinit
if [ -x "/etc/init.d/twms" ] || [ -e "/etc/init/twms.conf" ]; then
if [ ! -e "/etc/init/twms.conf" ]; then
update-rc.d twms defaults >/dev/null
fi
invoke-rc.d twms start || exit $?
fi
# End automatically added section
exit 0
|