35 lines
847 B
Plaintext
35 lines
847 B
Plaintext
|
#jinja2: lstrip_blocks: True
|
||
|
{{ ansible_managed | comment }}
|
||
|
[Install]
|
||
|
WantedBy=default.target
|
||
|
|
||
|
[Service]
|
||
|
Restart=on-failure
|
||
|
RestartSec=5s
|
||
|
|
||
|
ExecReload=/usr/bin/podman kill --signal=SIGHUP {{ __vault_container_name }}
|
||
|
|
||
|
[Container]
|
||
|
Image={{ vault_image }}
|
||
|
ContainerName={{ __vault_container_name }}
|
||
|
Exec=/usr/local/bin/docker-entrypoint.sh server
|
||
|
EnvironmentFile=/etc/containers/systemd/vault.env
|
||
|
{% for item in vault_volumes %}
|
||
|
Volume={{ item.name }}:{{ item.dest }}:Z
|
||
|
{% endfor %}
|
||
|
|
||
|
{% if vault_cap_add | length > 0 %}
|
||
|
AddCapability={{ vault_cap_add | join(" ") }}
|
||
|
{% endif %}
|
||
|
{% if vault_cap_drop | length > 0 %}
|
||
|
DropCapability={{ vault_cap_drop | join(" ") }}
|
||
|
{% endif %}
|
||
|
|
||
|
Network={{ vault_network }}
|
||
|
{% for item in vault_exposed_ports %}
|
||
|
PublishPort={{ item }}
|
||
|
{% endfor %}
|
||
|
{% for item in vault_podman_args %}
|
||
|
PodmanArgs={{ item }}
|
||
|
{% endfor %}
|