Created
March 3, 2011 15:29
-
-
Save jooooooon/852938 to your computer and use it in GitHub Desktop.
Cfengine: add line to /etc/crontab
This file contains 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
bundle agent cron_ensure_cfexecd_running { | |
files: | |
"$(g.crontab)" | |
edit_line => add_lines; | |
} | |
bundle edit_line add_lines | |
{ | |
insert_lines: | |
"*/5 * * * * root if [ `ps -efww | grep cf-execd | grep -v grep | wc -l` -eq 0 ]; then /var/cfengine/bin/cf-execd; fi"; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment