Python and cron jobs.
Steven Taschuk
staschuk at telusplanet.net
Tue Aug 5 03:31:03 EDT 2003
Quoth Fazer:
> I am wondering that if it is possible to add cron jobs via a web or
> shell interface? I can make Python act as a shell script and be
> called by a PHP script. But my main goal here is to be able to manage
> cronjobs. Add or remove certain crjob jobs etc...
>
> Can any kind soul shed some light on how I would accomplish this?
The question is a bit vague, I'm afraid.
If you just want to know how to invoke crontab(1) from a Python
script, look up os.popen() and friends in the standard library
documentation. As for getting the cron daemon to reload the
changed crontab, that's a nop in the crons I've seen; they check
for changes every minute anyway.
If you want to know something else, please specify.
--
Steven Taschuk staschuk at telusplanet.net
"What I find most baffling about that song is that it was not a hit."
-- Tony Dylan Davis (CKUA)
More information about the Python-list
mailing list