Dustin Kirkland [2008-09-13 14:59 -0000]:
> I put it in the init script such that it would be easy for an
> administrator to "stop" update-motd from running, by removing the script
> from /etc/cron.d.
>
> And the "start" restores the /etc/cron.d script by regenerating the
> script from the template in /usr/share, and reading the $FREQ_IN_MIN
> established by debconf question in /etc/default/update-motd.
But this is so much unlike the behaviour of all other daemons. init
scripts are used for starting/stopping processes, not
creating/removing configuration files. OTOH "rm /etc/cron.d/update-motd"
should cause the cronjob to not be run any more, instead the next boot
would restore it again by running the init script.
So the current package violates common practice of init scripts and
configuration files. Also, TBH it seems way too overengineered to me.
Why not drop the default file, init script, and all that black magic,
and ship /etc/cron.d/update-motd as a standard conffile with a ten
minute interval? It's still just an one-line file, thus it is not
significantly easier or harder to change/maintain than the default
file, and it would make the behaviour so much more obvious. You'd also
retain the possibility of changing the defaults in a future version,
which is impossible in the current setup.
Thanks for considering,
Martin
--
Martin Pitt | http://www.piware.de
Ubuntu Developer (www.ubuntu.com) | Debian Developer (www.debian.org)
Hi,
Dustin Kirkland [2008-09-13 14:59 -0000]: update- motd.
> I put it in the init script such that it would be easy for an
> administrator to "stop" update-motd from running, by removing the script
> from /etc/cron.d.
>
> And the "start" restores the /etc/cron.d script by regenerating the
> script from the template in /usr/share, and reading the $FREQ_IN_MIN
> established by debconf question in /etc/default/
But this is so much unlike the behaviour of all other daemons. init d/update- motd"
scripts are used for starting/stopping processes, not
creating/removing configuration files. OTOH "rm /etc/cron.
should cause the cronjob to not be run any more, instead the next boot
would restore it again by running the init script.
So the current package violates common practice of init scripts and d/update- motd as a standard conffile with a ten
configuration files. Also, TBH it seems way too overengineered to me.
Why not drop the default file, init script, and all that black magic,
and ship /etc/cron.
minute interval? It's still just an one-line file, thus it is not
significantly easier or harder to change/maintain than the default
file, and it would make the behaviour so much more obvious. You'd also
retain the possibility of changing the defaults in a future version,
which is impossible in the current setup.
Thanks for considering,
Martin www.piware. de
--
Martin Pitt | http://
Ubuntu Developer (www.ubuntu.com) | Debian Developer (www.debian.org)