diff options
author | Sébastien Leduc | 2015-08-18 16:54:16 +0200 |
---|---|---|
committer | Sébastien Leduc | 2015-08-18 16:54:16 +0200 |
commit | 980d280d3f55385245a6fb7753131689d7a7ef89 (patch) | |
tree | 217325f8186f767c7377171931780ec727e5ae6b /mediatomb.install | |
download | aur-mediatomb-git.tar.gz |
Initial commit
Diffstat (limited to 'mediatomb.install')
-rw-r--r-- | mediatomb.install | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/mediatomb.install b/mediatomb.install new file mode 100644 index 000000000000..f0a8162be736 --- /dev/null +++ b/mediatomb.install @@ -0,0 +1,20 @@ +pre_install() { + groupadd --system mediatomb + useradd -M --no-user-group --system --shell /bin/false --home /var/lib/mediatomb --gid mediatomb mediatomb && passwd -l mediatomb &>/dev/null + install --directory --owner=mediatomb --group=mediatomb "/var/lib/mediatomb" +} + +post_install() { + systemctl enable mediatomb.service + systemctl start mediatomb.service +} + +pre_remove() { + systemctl stop mediatomb.service + systemctl disable mediatomb.service +} + +post_remove() { + userdel mediatomb &>/dev/null + groupdel mediatomb &>/dev/null +}
\ No newline at end of file |