File: postinst

package info (click to toggle)
gross 1.0.4-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 1,664 kB
  • sloc: sh: 8,835; ansic: 7,330; makefile: 53; xml: 45
file content (37 lines) | stat: -rw-r--r-- 733 bytes parent folder | download | duplicates (7)
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
34
35
36
37
#! /bin/sh
# postinst script for gross

set -e

# lintian: postinst-does-not-load-confmodule
. /usr/share/debconf/confmodule

case "$1" in
    configure)
        DBDIR='/var/lib/gross'

        getent passwd gross > /dev/null || \
            adduser --system --home "$DBDIR" --no-create-home \
                    --disabled-password --group gross
        getent group gross > /dev/null || \
            addgroup --system gross 

        install -d -o gross -g gross -m 0700 "$DBDIR"
    ;;

    abort-upgrade|abort-remove|abort-deconfigure)

    ;;

    *)
        echo "postinst called with unknown argument \`$1'" >&2
        exit 1
    ;;
esac

#DEBHELPER#

# without this, debconf hangs after end of postinst.
#db_stop

exit 0