blob: 2261599e8d340e73cf3066db9de43db3b3fc9cec (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
## arg 1: the new package version
post_install() {
if ! getent passwd _rspamd >/dev/null; then
useradd -k /dev/null -r -m -c 'rspam daemon' -d /var/lib/rspamd -s /sbin/nologin _rspamd
passwd -l _rspamd >/dev/null
fi
mkdir -p /var/log/rspamd
mkdir -p /run/rspamd
chown _rspamd:_rspamd /var/log/rspamd
chown _rspamd:_rspamd /run/rspamd
}
## arg 1: the old package version
post_remove() {
if getent passwd _rspamd >/dev/null; then
userdel _rspamd
fi
}
# vim:set ts=2 sw=2 et:
|