postinst is in ola 0.10.5.nojsmin-3.
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 | #!/bin/sh -e
# postinst script for ola
#create the olad user, add it to groups
getent passwd olad > /dev/null || adduser --system --home /usr/lib/olad --no-create-home olad
getent group olad > /dev/null || addgroup --system olad
groups olad | grep dialout > /dev/null || adduser olad dialout
groups olad | grep plugdev > /dev/null || adduser olad plugdev
# setup the config dir
chown -R olad:olad /etc/ola
chmod g+s /etc/ola
# dh_installdeb will replace this with shell code automatically
# generated by other debhelper scripts.
# Automatically added by dh_installinit/10.10.5ubuntu1
if [ "$1" = "configure" ] || [ "$1" = "abort-upgrade" ]; then
if [ -x "/etc/init.d/olad" ]; then
update-rc.d olad defaults >/dev/null
invoke-rc.d olad start || exit $?
fi
fi
# End automatically added section
exit 0
|