aboutsummaryrefslogtreecommitdiffstats
path: root/systemd/mpd-notification.service
blob: ab9e265405a6dc18c07b2ff5aebc3222ad4c4878 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
[Unit]
Description=MPD Notification
# Do not require any service here! We do rely on mpd OR network (for
# a remote mpd instance). So let the user care.
# We want to order after, though. This makes sure the resource is
# available on start and mpd-notification can cleanly disconnect on
# system shutdown.
After=mpd.service network.target network-online.target

[Service]
Type=simple
# Using mpd user service can result in mpd-notification starting too early
# as systemd thinks mpd has finished initialization but socket is not yet
# available. So sleep for a second before starting.
# TODO: Remove workarount when upstream fix is released. Currently in git:
# http://git.musicpd.org/cgit/master/mpd.git/commit/?id=7b575f61
# http://git.musicpd.org/cgit/master/mpd.git/commit/?id=c85ba733
ExecStartPre=/usr/bin/sleep 1
ExecStart=/usr/bin/mpd-notification

[Install]
WantedBy=default.target