summaryrefslogtreecommitdiff
path: root/community/nsd/install
blob: 6e56e9ba18520c2978e7c63636ba469374797b0c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
post_install() {
	getent group nsd &>/dev/null || groupadd -r nsd >/dev/null
	getent passwd nsd &>/dev/null || useradd -r -g nsd -d /dev/null -s /bin/false -c nsd nsd >/dev/null
	chown nsd:nsd /var/db/nsd
	chmod 700 /var/db/nsd
}

post_upgrade() {
	usr/bin/systemd-tmpfiles --create nsd.conf || true
}

post_remove() {
	getent passwd nsd &>/dev/null && userdel nsd >/dev/null
	getent group nsd &>/dev/null && groupdel nsd >/dev/null
	true
}