summaryrefslogtreecommitdiff
path: root/roles/whawty/auth/app/templates/systemd.socket.j2
blob: f0432e3b02b9b7c13656d1a5064065e971aba65e (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=whawty.auth authentication agent for {{ whawty_auth_app.name }}/{{ item.key }}

[Socket]
Service=whawty-auth-{{ whawty_auth_app.name }}.service
FileDescriptorName={{ item.key }}
{% for socket in item.value.sockets %}
ListenStream={{ socket }}
{% endfor %}
RemoveOnStop=true
{% if 'user' in item.value %}
SocketUser={{ item.value.user }}
{% endif %}
{% if 'group' in item.value %}
SocketGroup={{ item.value.group }}
{% endif %}
{% if 'mode' in item.value %}
SocketMode={{ item.value.mode }}
{% endif %}

[Install]
WantedBy=sockets.target