[config-package-dev] transform

Benjamin Kaduk kaduk at MIT.EDU
Thu Mar 13 20:18:45 EDT 2014


On Thu, 13 Mar 2014, Patrick Schleizer wrote:

> Hi!
>
> At the moment as I understand it:
> - config file to be transformed should be available at package build
> time (provided by original package)
> - transformation script is applied at package build time
> - when upstream releases a new config file, these changes won't be
> included in the transformed config as long as the config package does
> not get upgraded
> - disadvantage: to be transformed package is a build dependency
> - disadvantage: config package must be updated every time upstream
> releases a new config that should be applied as well
>
> Wouldn't it be better to just apply the patch every time upstream
> releases a new config file?

It has been some time since I thought about this question, but I believe 
the issue is what happens in the case that the transformation script 
fails: if the transformation is applied at package build time, the package 
build fails, and the old version of the configuration package remains in 
the archive, so clients never see a broken package.  If the transformation 
is applied as a trigger on updates of the package being configured, then a 
failure of the transformation script could leave the client system in a 
broken state.

In general (in, say, Debian or Ubuntu proper), packages should not be 
changing their installed configuration packages within a given release 
branch (Debian stable is supposed to be stable, and all), so normally it 
suffices to just rebuild all configuration packages at the release of a 
new upstream OS version.

> In my case, I only wish to append a few lines below in the config of
> what upstream does above.

This is the sort of thing that motivates the creation of conf.d/ 
directories for placing configuration file snippets.  It might be worth 
asking upstream to consider adding such support; then the configuration 
package can just install a snippet to that directory.

-Ben Kaduk


More information about the config-package-dev mailing list