'Systemd service with multiple execStart and watchdog for each execStart
I would know if it's possible to create service with multiple execStart where I can monitor each execStart with a watchdog such as:
[Unit]
Description="test service"
[Service]
Type=oneshot
ExecStart=/home/program1
ExecStart=/home/program2
WatchdogSec= 2
Restart=on-failure
RestartSec= 1
[Install]
WantedBy=default.target
Or it's better if I use template service for example [email protected] with this syntax:
[Unit]
Description="test service %i"
[Service]
ExecStart=/home/%i
WatchdogSec= 2
Restart=on-failure
RestartSec= 1
[Install]
WantedBy=default.target
Thanks in advance.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
