mirror of
https://github.com/community-scripts/ProxmoxVE
synced 2025-01-10 19:05:09 +00:00
Alertmanager: Change the way how the systemd unit file is written to disk
Co-authored-by: Michel Roegl-Brunner <73236783+michelroegl-brunner@users.noreply.github.com>
This commit is contained in:
parent
432d12e8e4
commit
51a5e4362e
@ -33,7 +33,7 @@ echo "${RELEASE}" >/opt/${APPLICATION}_version.txt
|
||||
msg_ok "Installed Prometheus Alertmanager"
|
||||
|
||||
msg_info "Creating Service"
|
||||
service_path="/etc/systemd/system/prometheus-alertmanager.service"
|
||||
cat <<EOF >/etc/systemd/system/prometheus-alertmanager.service
|
||||
echo "[Unit]
|
||||
Description=Prometheus Alertmanager
|
||||
Wants=network-online.target
|
||||
@ -50,7 +50,8 @@ ExecStart=/usr/local/bin/alertmanager \
|
||||
ExecReload=/bin/kill -HUP \$MAINPID
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target" >$service_path
|
||||
WantedBy=multi-user.target"
|
||||
EOF
|
||||
systemctl enable -q --now prometheus-alertmanager
|
||||
msg_ok "Created Service"
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user