Make service files more consistent

This commit is contained in:
Joakim Soderlund 2018-09-03 19:54:10 +02:00
parent 22b6ed1c9c
commit 70b0261710
3 changed files with 7 additions and 6 deletions

View file

@ -38,6 +38,7 @@
notify: Restart Deluge
register: result
- name: Enabled service
- name: Enable service
# Needed to override SysV init.
command: systemctl enable deluged
when: result is changed

View file

@ -1,13 +1,12 @@
[Unit]
Description=Deluge Daemon
Documentation=man:deluged
After=network-online.target
[Service]
Type=simple
User={{ deluge.user }}
Group={{ deluge.user }}
UMask=002
WorkingDirectory={{ deluge.home }}
ExecStart=/usr/bin/deluged -c {{ deluge.conf }} -d
Restart=on-failure
TimeoutStopSec=300

View file

@ -1,13 +1,14 @@
[Unit]
Description=OpenTracker
After=network.target
After=network-online.target
[Service]
Type=simple
User={{ opentracker.user }}
WorkingDirectory={{ opentracker.conf }}
Group={{ opentracker.user }}
WorkingDirectory={{ opentracker.home }}
ExecStart=/usr/local/bin/opentracker -f "{{ opentracker.conf }}/config"
Restart=on-abort
Restart=on-failure
[Install]
WantedBy=multi-user.target