desktop/unvanquished/unvanquished.install

26 lines
500 B
Plaintext
Raw Permalink Normal View History

2013-12-05 05:31:20 +08:00
_add_server_user() {
if ! getent passwd unvanquished >/dev/null; then
useradd -rM -d /var/lib/unvanquished-server -c "Unvanquished dedicated server" -s /bin/false unvanquished
fi
}
_delete_server_user() {
if getent passwd unvanquished >/dev/null; then
userdel unvanquished
2014-11-11 19:48:10 +08:00
groupdel unvanquished
2013-12-05 05:31:20 +08:00
fi
}
_chown_server_home() {
chown -R unvanquished:unvanquished /var/lib/unvanquished-server
}
post_install() {
_add_server_user
_chown_server_home
}
post_remove() {
_delete_server_user
}