Role service-fastd: use own systemd unit fastd@.service

- original uses %I which does not escaping, so dashes will be replaced
by slashes
- use %i instead of %I
This commit is contained in:
Tobias Hachmer 2017-10-08 11:35:22 +02:00
parent c56dc3504c
commit f18e53e4e7
2 changed files with 20 additions and 0 deletions

View file

@ -12,3 +12,12 @@
systemd:
name: fastd
masked: yes
- name: write systemd unit fastd@.service
template:
src: fastd@.service.j2
dest: /etc/systemd/system/fastd@.service
owner: root
group: root
mode: 0644
notify: reload systemd

View file

@ -0,0 +1,11 @@
[Unit]
Description=Fast and Secure Tunnelling Daemon (connection %i)
After=network.target
[Service]
Type=notify
ExecStart=/usr/bin/fastd --syslog-level info --syslog-ident fastd@%i -c /etc/fastd/%i/fastd.conf
ExecReload=/bin/kill -HUP $MAINPID
[Install]
WantedBy=multi-user.target