sous-chefs / apt

Development repository for the apt cookbook
https://supermarket.chef.io/cookbooks/apt
Apache License 2.0
202 stars 266 forks source link

Confdef #221

Closed whiteley closed 7 years ago

whiteley commented 7 years ago

Description

Provides attribute control for what APT does when it encounters configuration file changes while managing packages. This can avoid errors like the following:

 ==> File on system created by you or by a script.
 ==> File also in package provided by package maintainer.
   What would you like to do about it ?  Your options are:
    Y or I  : install the package maintainer's version
    N or O  : keep your currently-installed version
      D     : show the differences between the versions
      Z     : start a shell to examine the situation
 The default action is to keep your current version.

The general opinion seems to be that the combination of --force-confdef and --force-confold is the safest option for unattended installs but I left the default behavior as it was. Without setting any attributes it will still crash out with the above type error.

More information about the options is available from man dpkg, I tried to pare the descriptions down to something useful in the README.

Check List

tas50 commented 7 years ago

@whiteley You'll need to sign these commits off for the DCO before we can merge this in.

thommay commented 7 years ago

We'll be fixing this in chef/chef#5698 in the next month or two. (but that's not to say this is bad for old versions)

whiteley commented 7 years ago

@thommay awesome, thanks for the info.

tas50 commented 7 years ago

Thanks for the specs