provide mpd user service

The Arch package used to provide this. Now it doesn't.

To use this, you'd just enable and start it as your user.

    $ systemctl --user enable mpd.service
    $ systemctl --user start mpd.service

Existing users can remove the override we used to install, since that is
now redundant.

    # rm -r /etc/systemd/user/mpd.service.d
This commit is contained in:
Pig Monkey 2016-12-11 21:48:52 -08:00
parent 74de6fb893
commit 938e8d27ff
3 changed files with 15 additions and 10 deletions

View file

@ -1,3 +0,0 @@
[Service]
ExecStart=
ExecStart=/usr/bin/firejail /usr/bin/mpd --no-daemon

View file

@ -0,0 +1,13 @@
[Unit]
Description=Music Player Daemon
After=network.target sound.target
[Service]
ExecStart=/usr/bin/firejail /usr/bin/mpd --no-daemon
# allow MPD to use real-time priority 50
LimitRTPRIO=50
LimitRTTIME=infinity
[Install]
WantedBy=multi-user.target

View file

@ -16,13 +16,8 @@
tags:
- firejail
- name: Create mpd systemd unit file directory
file: path=/etc/systemd/user/mpd.service.d state=directory
tags:
- firejail
- name: Push mpd socket unit file
copy: src=mpd-service-override.conf dest=/etc/systemd/user/mpd.service.d/override.conf
- name: Push mpd service file
copy: src=mpd.service dest=/etc/systemd/user/mpd.service
notify:
- reload systemd config
tags: