File: minetest-server.postinst

package info (click to toggle)
minetest 0.4.15%2Brepack2-1
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 30,732 kB
  • ctags: 13,048
  • sloc: cpp: 110,598; xml: 77,537; ansic: 4,149; sh: 853; makefile: 788; python: 659; java: 484
file content (32 lines) | stat: -rw-r--r-- 756 bytes parent folder | download | duplicates (5)
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
#!/bin/sh

set -e

case "$1" in
  configure)
    if ! getent passwd Debian-minetest >/dev/null; then
      adduser \
          --disabled-password \
          --quiet \
          --system \
          --home /var/games/minetest-server \
          --no-create-home \
          --gecos "Minetest dedicated server" \
          --ingroup games \
          --force-badname Debian-minetest
    fi
    install -d /var/games
    install -d /var/games/minetest-server
    install -d /var/log/minetest
    chown Debian-minetest:games /var/games/minetest-server
    chown Debian-minetest:games /var/log/minetest
  ;;
  abort-upgrade|abort-remove|abort-deconfigure)
  ;;
  *)
    echo "postinst called with unknown argument \`$1'" >&2
    exit 1
  ;;
esac

#DEBHELPER#