Issue #746 has been updated by Felix Frank.
Hacking away at a proof of concept, I find myself facing a choice. 1. Make a slick and clean file generator and parser. This would be nice because it can be implemented in a very straight-forward fashion, without all the wiggle room that allowed that ultimately led to the crontab provider being a bug-ridden beast. On the other hand, though, it will clobber existing cron.d files and not only rid them of comments and spacing, but also of additional cronjobs besides the one being declared in the named resource! It will also likely falsely identify environment lines of such victim jobs and merge them with the managed job's environment (except the environment itself is managed as well). 2. Be flexible. Manage environment, schedule and command of what we *assume* is the main cronjob in the cron.d file and try and leave anything else intact. If one would want to go that way, the best way to do it would be to base the cron.d provider on parsedfile, hands down. We could reuse the crontab provider implementation (perhaps inherit it, or create a common base class), which might save some implementation overhead. On the downside, we'd inherit the bugs and implementation complexity. After all, the crontab provider by now contains more code to workaround Parsedfile's limitations than for getting actual work done (or so it feels). I'd personally prefer number 1, if we can live with the radical implications. ---------------------------------------- Feature #746: Create Cron provider for /etc/cron.d entries https://projects.puppetlabs.com/issues/746#change-87964 * Author: Udo Waechter * Status: Accepted * Priority: High * Assignee: * Category: cron * Target version: 3.x * Affected Puppet version: 0.22.1 * Keywords: * Branch: ---------------------------------------- Provide support for managing cron job through /etc/crontab. *Former bug text: *Under darwin, the root user is usually disabled, thus it's crontab does not work. As a work around it is possible to create those jobs in /etc/crontab I did not look into the cron provider, but I guess the change to the code is minimal. thanks. -- You have received this notification because you have either subscribed to it, or are involved in it. To change your notification preferences, please click here: http://projects.puppetlabs.com/my/account -- You received this message because you are subscribed to the Google Groups "Puppet Bugs" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/puppet-bugs?hl=en. For more options, visit https://groups.google.com/groups/opt_out.
