Bug #3396
closedDebian/Ubuntu packages should support "allow untrusted" (optionnaly)
Description
In some cases Debian/Ubuntu packages wait forever:
Q:env DEBIAN_FRONTEND= ...:Reading package lists...
Q:env DEBIAN_FRONTEND= ...:Building dependency tree...
Q:env DEBIAN_FRONTEND= ...:Reading state information...
Q:env DEBIAN_FRONTEND= ...:Reading extended state information...
Q:env DEBIAN_FRONTEND= ...:Initializing package states...
Q:env DEBIAN_FRONTEND= ...:The following NEW packages will be installed:
Q:env DEBIAN_FRONTEND= ...: git git-man{a} liberror-perl{a} patch{a}
Q:env DEBIAN_FRONTEND= ...:0 packages upgraded, 4 newly installed, 0 to
remove and 87 not upgraded.
Q:env DEBIAN_FRONTEND= ...:Need to get 9361 kB of archives. After
unpacking 18.3 MB will be used.
Q:env DEBIAN_FRONTEND= ...:WARNING: untrusted versions of the following
packages will be installed!
Q:env DEBIAN_FRONTEND= ...:
Q:env DEBIAN_FRONTEND= ...:Untrusted packages could compromise your
system's security.
Q:env DEBIAN_FRONTEND= ...:You should only proceed with the installation
if you are certain that
Q:env DEBIAN_FRONTEND= ...:this is what you want to do.
Q:env DEBIAN_FRONTEND= ...:
Q:env DEBIAN_FRONTEND= ...: git-man git
Q:env DEBIAN_FRONTEND= ...:
Q:env DEBIAN_FRONTEND= ...:Do you want to ignore this warning and proceed
anyway?
This can be pretty easily solved in CFengine 3 by putting the following into cfengine_stdlib.cf:
have_aptitude::
package_add_command => "/usr/bin/env DEBIAN_FRONTEND=noninteractive LC_ALL=C /usr/bin/aptitude -o Dpkg::Options::=--force-confold -o Dpkg::Options::=--force-confdef --assume-yes install";
Or:
have_aptitude::
package_add_command => "/usr/bin/env DEBIAN_FRONTEND=noninteractive LC_ALL=C /usr/bin/aptitude -o Dpkg::Options::=--force-confold -o Dpkg::Options::=--force-confdef --assume-yes --allow-untrusted install";