Skip to content

Instantly share code, notes, and snippets.

@sukrit007
Created February 6, 2015 01:00
Show Gist options
  • Save sukrit007/574bfb21fea7bdf1711f to your computer and use it in GitHub Desktop.
Save sukrit007/574bfb21fea7bdf1711f to your computer and use it in GitHub Desktop.
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"
@scole-scea
Copy link

And that gist is up, if anybody else needs help. https://gist.github.com/scole-scea/177a367c51d0b93d51f6

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment