We invoke /usr/bin/apt inside of the ansible module. When that command
exits, it doesn't always include a helpful error message. Include the
exit code so that user's have all the information we can gice them as to
why apt failed.
Addresses #19128
(cherry picked from commit b4f976e9b9)
* rpm_key: Decode bytes to string to work with Python 3 (#20326)
The read() method will return bytes we need to then decode() those bytes
to a string before trying to match() it using the re module.
* Make the rpm_key pgp regex more robust on both py2 and py3
(cherry picked from commit cee8cc2a52)
Recent Python3 versions require open() to specify binary mode if the data is anything other than text.
Python3: Use int() instead of long() in unarchive
Changes long() to int() for CRC values in the unarchive module. Affects unarchiving of zip files. Since CRC values in zipfile are 32 bits the behaviour should be unchanged even in Python 2.
When retrieving file contents for diffing we need to get the contents as
binary. Otherwise python3 will try to convert the file to text and fail
with non-decodable contents.
Fixes#23171
(cherry picked from commit 2fdb8e7f90)
Ansible will now automatically retry a connection if SSH returns an error:
mux_client_hello_exchange: write packet: Broken pipe
This is probably a bug in SSH, but because it's safe to retry this
connection there is no need for Ansible to fail because of it.
(cherry picked from commit 9f0be5a556)
removed bare vars
now environment inheritance correclty prepends
this allows more local to override more general
fixes#23180
(cherry picked from commit df5895e585)
Not a critical blocker so we'll push this to 2.3.1 instead of trying to
get it into 2.3.0 (Just too late in the development cycle to push it out
now).
This reverts commit 9a850db605.
* Check for provider values inside check_args of respective network code
* Partial revert of b9ee5aa
The no_log change is okay, but take out the action result munging
(cherry picked from commit 86c714548f)
The return was being re-written instead of updated so warnings were
lost. This patch now updates the result instead of replacing it.
(cherry picked from commit d6787632c9)
We were hard-coding the protocol, port and validate_certs on
eos EAPI via the action plugin.
Put defaults on the eos_argument_spec and pull those values from it.
(cherry picked from commit 3537b24742)
For update parameter add 'override' as acceptable value.
'override' name is in sync with junos naming convention.
(cherry picked from commit 0cd50f0706)
the command dict in the iosxr module_utils wasn't encoding the request
to json. this patch will fix that problem
(cherry picked from commit f0008248d4)
* 'unable to open shell' -> direct to web help
The "unable to open shell" error is returned for a number of different,
direct people to online docs (we we can update out of band of releases)
to guide them though the various solutions.
* fix pep8 errors
(cherry picked from commit 529df8640b)