I am setting up a new Server (Debian 10). I need to install required packages (and some Perl Modules) with_items using default package manager (apt). When I run my playbook, I receive the following failure:
`
failed: [deb7ex6405] (item=libexpat1-dev) => {“ansible_loop_var”: “item”, “cache_update_time”: 1559401245, “cache_updated”: false, “changed”: false, “item”: “libexpat1-dev”, “msg”: "'/usr/bin/apt-get -y -o "Dpkg::Options::=–
force-confdef" -o "Dpkg::Options::=–force-confold" --simulate install ‘libexpat1-dev’’ failed: E: Unable to correct problems, you have held broken packages.\n", “rc”: 100, “stderr”: "E: Unable to correct problems, you have held
broken packages.\n", “stderr_lines”: [“E: Unable to correct problems, you have held broken packages.”], “stdout”: "Reading package lists…\nBuilding dependency tree…\nReading state information…\nSome packages could not be
installed. This may mean that you have\nrequested an impossible situation or if you are using the unstable\ndistribution that some required packages have not yet been created\nor been moved out of Incoming.\nThe following information
may help to resolve the situation:\n\nThe following packages have unmet dependencies:\n libexpat1-dev : Depends: libexpat1 (= 2.1.0-1+deb7u2) but 2.1.0-1+deb7u4 is to be installed\n", “stdout_lines”: [“Reading package lists…”,
“Building dependency tree…”, “Reading state information…”, “Some packages could not be installed. This may mean that you have”, “requested an impossible situation or if you are using the unstable”, "distribution that some required
packages have not yet been created", “or been moved out of Incoming.”, “The following information may help to resolve the situation:”, “”, “The following packages have unmet dependencies:”, " libexpat1-dev : Depends: libexpat1 (=
2.1.0-1+deb7u2) but 2.1.0-1+deb7u4 is to be installed"]}
`
Ansible Version:
`
ansible 2.8.0
config file = /etc/ansible/ansible.cfg
configured module search path = [u’/home/kjames/.ansible/plugins/modules’,
u’/usr/share/ansible/plugins/modules’]
ansible python module location = /usr/lib/python2.7/site-packages/ansible
executable location = /usr/bin/ansible
python version = 2.7.5 (default, Apr 9 2019, 14:30:50) [GCC 4.8.5 20150623
(Red Hat 4.8.5-36)]
`
Ansible Controller:
NAME="CentOS Linux" VERSION="7 (Core)"
Destination Server:
PRETTY_NAME="Debian GNU/Linux 7 (wheezy)" NAME="Debian GNU/Linux" VERSION_ID="7"
new-buildserver.yaml:
`