Last active
November 3, 2023 03:59
-
-
Save elyscape/7e8c1ea7ae186fd780c59e8cbf87181d to your computer and use it in GitHub Desktop.
Systemd configuration for healthchecks.io heartbeat
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ENDPOINT=https://whatever |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Unit] | |
Description=Heartbeat | |
After=network.target network-online.target | |
Requisite=network.target network-online.target | |
[Service] | |
Type=oneshot | |
EnvironmentFile=/etc/default/heartbeat | |
ExecStart=/usr/bin/curl -fsS -m 10 --retry 3 ${ENDPOINT} | |
StandardOutput=null | |
DynamicUser=true |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Unit] | |
Description=Send heartbeat every 5 minutes | |
[Timer] | |
OnCalendar=*-*-* *:00/5:00 | |
Persistent=true | |
[Install] | |
WantedBy=timers.target |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment