Type = "cmd" # command execution Category = "Test jobs" # jobs category name Description = "print 'Hello' every minute" # job description Cron = "* * * * *" # cron instructions Command = "echo Hello" # command to execute NumberOfRestartAttemts = 3 # number of restart attemts RestartSec = 5 # the time to sleep before restarting a job (seconds) RestartRule = "on-error" # Configures whether the job shall be restarted when the job process exits OnSuccessCmd = "echo 'Job finished.'" # execute cmd on job success OnErrorCmd = "echo 'Error occurred: {{.Error}}'" # execute cmd on job error # HTTP client callbacks OnSuccessHttpGetUrl = "http://127.0.0.1/alerts?title={{.JobName}}%20finished" OnErrorHttpGetUrl = "http://127.0.0.1/alerts?title={{.JobName}}%20failed&message={{.Error}}&tags=warning" OnSuccessHttpPostUrl = "http://127.0.0.1/alerts" OnSuccessMessageFmt = "Job {{.JobName}} finished." OnErrorHttpPostUrl = "http://127.0.0.1/alerts" OnErrorMessageFmt = "Job {{.JobName}} failed:\n\n{{.Error}}"