[17:37] hi.. i'm looking to use an upstart job (task?) to run a program (ansible-pull) periodically, in an end-to-end fashion. that is, i want ansible-pull to run all the way through before the next run begins. also, i'd like a sleep period to expire after ansible-pull runs.. i think i understand most of what i need to know.. however, i'm unsure of how best to do the loop.. it seems respawn only works for exit non-zero.. any ideas? [20:59] I'm writing a custom task. In the upstart cookbook, it says that session jobs will be looked for in /usr/share/ustart/sessions, but I put a job there and it's not in the list of upstart jobs as advertised in the upstart cookbook. but if i put my job in /etc/init, it's there. :~( [22:34] quizme: /usr/share/upstart/session/* jobs are only in effect in graphical user sesions. [22:34] quizme: use e.g. $ initctl --system list [22:34] or $ initctl --user list [22:34] to tell them appart. [22:34] xnox oh [22:35] quizme: similarly $ initctl --system start | stop | restart, etc. [22:35] xnox is there a way to enable them on the server ? [22:35] quizme: not really no, but there is a hack/workaround in the cookbook as how to do it. (basically a system job that auto-launches per-user session for the users you want it for) [22:36] quizme: it's a bit tricky, because on terminal login, you need to query the UPSTART_SESSION var & set it for your self & also get some other vars. [22:36] but it should work =) [22:37] basically, I'm writing an application-specific task that i want to run once per hour. for some reason I was thinking to use upstart instead of cron, is that wrong-headed ? [22:39] well i was planning to make an upstart task, then call the upstart task from cron. Then an upstart even would fire when it was finished and run another job. [22:39] "upstart event would fire" i mean [22:39] xnox: what do u think? [22:40] xnox should i just use bash+cron minus upstart ? [22:43] quizme: there was a plan for temporal/periodic events. [22:43] quizme: one thing you need to keep in mind is that - you cant start a running job again. [22:44] quizme: so your cron job can be: stop myjob; sleep 10; start myjob. and cron it to run once a day or some such. [22:44] quizme: cron is reliable way to do stuff. [22:45] quizme: you can instead emit events if you want via cron. E.g. cron every midnight to do $ initctl emit FOX_SAYS=midnight [22:45] or simly $ initctl emit midnight [22:46] and then your jobs can do "star on midnight" or "start on FOX_SAYS=midnight" or "start on FOX_SAYS" [22:46] oh yeah that's interesting [22:46] then when upstart takes over cron, my script will already work [23:45] quizme: i don't think upstart will take over cron =) instead it will provide interface akeen of "start on every 5 minutes" or "start on 10 minutes after runlevel=2" [23:53] xnox oh, ok, i thought it was going to take over cron, and then the world. [23:53] quizme: no, upstart is event based init system. And it does events and it does init. [23:56] quizme: you may be thinking of systemd software collection, that project has an index page of daemons/commands that is does and plans to add even more http://www.freedesktop.org/software/systemd/man/ [23:56] This index contains 296 entries, referring to 144 individual manual pages.