2017-04-24 10:48:25 -04:00
|
|
|
[Unit]
|
|
|
|
Description=vault server
|
2018-05-25 16:52:12 -04:00
|
|
|
Requires=network-online.target{% if config.storage and config.storage.type == "consul" %} consul.service{% endif %}
|
2018-05-15 02:36:50 -04:00
|
|
|
After=network-online.target{% if config.storage and config.storage.type == "consul" %} consul.service{% endif %}
|
2017-04-24 10:48:25 -04:00
|
|
|
|
|
|
|
[Service]
|
|
|
|
EnvironmentFile=-/etc/sysconfig/vault
|
2018-05-15 02:13:54 -04:00
|
|
|
User={{ user }}
|
|
|
|
Group={{ group }}
|
2018-05-15 02:36:50 -04:00
|
|
|
ExecStart=/usr/local/bin/vault server {% if config.dev_mode %}-dev{% else %}-config="/etc/vault.d/config.hcl"{% endif %}
|
2018-05-15 00:42:18 -04:00
|
|
|
ExecReload=/bin/kill -signal HUP $MAINPID
|
|
|
|
ExecStop=/usr/local/bin/vault operator step-down
|
|
|
|
Restart=on-failure
|
|
|
|
CapabilityBoundingSet=CAP_SYSLOG CAP_IPC_LOCK
|
2018-05-15 02:45:25 -04:00
|
|
|
AmbientCapabilities=CAP_IPC_LOCK
|
2018-05-15 00:42:18 -04:00
|
|
|
SecureBits=keep-caps
|
|
|
|
NoNewPrivileges=yes
|
|
|
|
KillSignal=SIGINT
|
2018-05-25 16:52:12 -04:00
|
|
|
|
|
|
|
[Install]
|
|
|
|
WantedBy=multi-user.target
|