Skip to content

Instantly share code, notes, and snippets.

View scole-scea's full-sized avatar

Steven Cole scole-scea

View GitHub Profile
@sukrit007
sukrit007 / systemd-reload.service
Created February 6, 2015 01:00
Systemd Reload Hack for Fleet
[Unit]
Description=Systemd Reload Hack for coreos fleet
After=fleet.service
[Service]
Restart=always
RestartSec=20s
ExecStart=/bin/bash -c "while true; do if systemctl -all list-units | grep -e '@.*not-found.*inactive.*dead.*'; then systemctl daemon-reload; fi; systemctl -all list-units | grep '@[0-9].*loaded.*inactive.*dead.*' | awk '{print $1}' | xargs systemctl restart; sleep 120s; done"