[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Init scripts as conffiles

* Jesús M. Navarro <jesus.navarro@undominio.net> [110215 20:40]:
> Anyway, my position would be that init script shouldn't have to be config
> files.  For this to be true these steps should need to be worked on:
> 1) See for boot dependencies not being stablished in the init script itself (a
> sourced directory under /etc/defaults?)
> 2) All init scripts whose related daemon accepts params on start or that
> define any kind of "global" variable (i.e.: not strictly related to Debian
> internals) should source an /etc/default-related file.
> 3) *Maybe* think about a general way for any init script to source from some
> file/dir if it exists.
> 4) Once developers are comfortable that the vast majority of init script
> honour these previous points, deprecate init scripts as being considered
> config files and file as a bug any time a sysadmin really needs to still edit
> one of them.

A sysadmin never has the edit any of those files. If they need to do
something special they can always change the kernel to patch the init
system to change what the script can do in arbitrary ways. </sarcasm>

While such scripts should allow all reasonable and forseeable
configuration settings be applyable outside, there are still all the
"unreasonable" and unforseeable changes that happen every day.
(execute some additional clean-up or preparational command just before,
run something two times or differently, ...).

If a admin is not able to do those, it's a crap system. So at least
every script should be overrideable by some script the admin supplies.

So what is the advantage of not having those files in /etc? (In
/etc/ they should be config files (ideally conffiles). If they are not
conffiles, they do not belong in /etc).

The advantage of having them in /etc are:

- every user understands how to change them (no need to find out where
  to copy a script so it overrides the distribution suplied one).
- if there are changes the usual conffile handling make sure one notes
  if the original file changes

	Bernhard R. Link

Reply to: