On 2014-11-09 19:01, Stefan Fritsch wrote: > On Sunday 09 November 2014 14:21:34, Andreas Beckmann wrote: >> I'm not sure whether (or how) dpkg-maintscript-helper mv_conffile >> can be used reliably to rename a conffile and switch ownership to >> another package at the same time. > > I don't see how there is any way to handle rename and takeofer of > conffiles at the same time at all. If the rename is done in apache2.2- > common, how would it know if something went wrong and it has to revert > the changes?
looks like we have the opportunity to test and implement this right now :-) from the dpkg-maintscript-helper mv_conffile manpage: Current implementation: the preinst checks if the conffile has been modified, if yes it's left on place otherwise it's renamed to old-conffile.dpkg-remove. On configuration, the postinst removes old- conffile.dpkg-remove and renames old-conffile to new-conffile if old-conffile is still available. On abort-upgrade/abort-install, the postrm renames old-conffile.dpkg-remove back to old-conffile if required. that process would have to be distributed to two packages ... but right now I'm not even sure how this case is handled: * package version 1 has conffile foo with content "foo" * user modifies this to set "foobar" * package version 2 renames the conffile to bar and changes content to "bar" Does dpkg prompt about this modification? Should it? > I think dpkg needs to provide an explicit interface for marking > conffiles as removed. Or piuparts should just ignore missing obsolete > conffiles. piuparts is relying on debsums for this ... debsums has already been taught not to complain about obsolete conffiles that are no longer owned by a package > But I will do an upload that removes the obsolete conffiles. Then > doing tests with the renamed/taken over conffiles may become easier. That's a good idea. Let's see what is remaining afterwards. Andreas -- To UNSUBSCRIBE, email to debian-apache-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org Archive: https://lists.debian.org/545ff498.5090...@debian.org