renew_consul_certificates/templates/consul-certs.service.j2

16 lines
579 B
Plaintext
Raw Normal View History

2023-04-29 19:46:58 +00:00
[Unit]
Description=Automatic renewal of consul certificate using consul-template
Requires=network-online.target
After=network-online.target consul.service
ConditionFileNotEmpty={{ renew_consul_certificates_config_dir }}/consul_config.hcl
[Service]
User={{ renew_consul_certificates_consul_user }}
Group={{ renew_consul_certificates_consul_group }}
ExecStart=/usr/bin/consul-template $OPTIONS -config={{ renew_consul_certificates_config_dir }}/consul_config.hcl
ExecReload=/bin/kill --signal HUP $MAINPID
KillSignal=SIGINT
Restart=on-failure
[Install]
WantedBy=multi-user.target