Added DPKG options which lardcanoe suggested

This commit is contained in:
Remy 2013-02-07 08:00:02 +01:00
parent fde27ae26e
commit d4a928e302

4
apt
View file

@ -174,9 +174,9 @@ def remove(m, pkgspec, cache, purge=False):
m.exit_json(changed=True)
def upgrade(m, mode="yes"):
upgrade_command = "upgrade"
upgrade_command = '-o "Dpkg::Options::=--force-confdef" -o "Dpkg::Options::=--force-confold" upgrade'
if mode == "dist":
upgrade_command = "dist-upgrade"
upgrade_command = '-o "Dpkg::Options::=--force-confdef" -o "Dpkg::Options::=--force-confold" dist-upgrade'
cmd = "%s -q -y %s" % (APT, upgrade_command)
rc, out, err = m.run_command(cmd)
if rc: