Commit Graph

11859 Commits (eef7bf7e4b1267ae17622d744d7deee8fc5a67bd)

Author SHA1 Message Date
Brian Coca ba487253bb
password lookup, handle ident properly when saved (#80251) (#80310)
* password lookup, handle ident properly when saved (#80251)

* password lookup, handle ident properly when saved

  Currently we format and save ident when present but we didn't account for this when reading the saved file
  Also added some more robust error handling.

(cherry picked from commit 0fd88717c9)

* fix try block indent# https://chris.beams.io/posts/git-commit/

* clog

(cherry picked from commit 97c8da7783)

* fix bad merge indentation
2 years ago
Martin Krizek d5a36b8734
Change ansible_job_id format (#79951) (#80282)
* Change ansible_job_id format

...to be something that does not resemble float or other type which
value could be changed by literal_eval that jinja2_native uses.

Specifically the format of '%d.%d' is converted from str to float and
then back to float which may result in truncating the number resulting
in the job not being found because the job id does not exist.

(cherry picked from commit 09e0fb3516)
2 years ago
Sloane Hertel 62a353c085
fix using templated values for include/import role FA (#80320) (#80378)
* fix using templated values for include/import role options 'public', 'allow_duplicates', and 'rolespec_validate'

* pass templated values without changing the instance

* Fix templating by setting always_post_validate to True and calling IncludeRole.post_validate() instead

ci_complete

* add changelog

(cherry picked from commit 666188892e)
2 years ago
Jordan Borean 495d48d51e
Ansible.Basic - Improve temporary file cleanup process (#80293) (#80324)
* Ansible.Basic - Improve temporary file cleanup process

* Add comment on struct value used

(cherry picked from commit ba4505f5cb)
2 years ago
Sloane Hertel 4aa682003d
Fetch signatures from galaxy after the dependency resolver runs (#80334) (#80398)
Reduce the number of Galaxy API calls made during dependency resolution by fetching remote signatures afterwards, since these are not used in backtracking.

Reduce the verbosity to `-vvvv` (to match other Galaxy API calls) to see this activity.

Co-authored-by: Sviatoslav Sydorenko <webknjaz@redhat.com>
(cherry picked from commit 460abe0cef)
2 years ago
Matt Clay c4b33c7ce8
[stable-2.14] ansible-test - Add support for argcomplete 3 (#80482) (#80485)
(cherry picked from commit 0371ea08d6)
2 years ago
Matt Clay fb76b9e8a4
[stable-2.14] ansible-test - Fix packaging change classification (#80360) (#80361)
(cherry picked from commit 5d64024f1a)
2 years ago
Felix Fontein 08297ce0db
[2.14] ansible-doc: fix broken seealso links in text output (#80285)
* ansible-doc: fix broken seealso links in text output (#80280)

* Fix broken URLs.

* Also remove auto-generated description for modules outside ansible.builtin.

(cherry picked from commit fafb23094e)

* Fix URL processing. (#80295)

(cherry picked from commit 086ae42209)
2 years ago
Matt Clay 7bb078bd74
[stable-2.14] Fix url lookup test to use test container (#80284) (#80287)
(cherry picked from commit 054aa92158)
2 years ago
Matt Clay 9f723d7123
[stable-2.14] 📦 Switch sdist build-system to pure setuptools (#80255) (#80261)
* [stable-2.14] 📦 Switch sdist build-system to pure setuptools (#80255)

This patch modifies the in-tree build backend to build sdists that swap
out pointers to it in the `pyproject.toml`'s `[build-system]` section.

The effect of this is that the first build from source (for example,
from a Git checkout) uses our PEP 517 in-tree build backend. But the
produced tarball has `build-backend` set to `setuptools.build_meta`
which is the native build backend of `setuptools`. So any following
builds from that sdist will skip using the in-tree build backend,
calling the setuptools' one.
The good news is that if the first build generated the manpages, they
will be included and won't go anywhere even though, a different build
system is in place.

Combined with #80253, this will make sure not to modify the current
source checkout on that first build.

Co-authored-by: Matt Clay <matt@mystile.com>
(cherry picked from commit 7097df3eed)

Co-authored-by: Sviatoslav Sydorenko <webknjaz@redhat.com>

* Make PEP 517 mutation tests use pinned old setuptools (#80262)

* Pin setuptools to lowest supported @ PEP 517 test

This allows catching the behavior of builds under old setuptools.

* Stop invoking `setup.py install` in tests

This is not the part we care about since it involves dealing with the
external runtime dependencies rather than building our source
distribution.

(cherry picked from commit eebfd71a6d)

---------

Co-authored-by: Sviatoslav Sydorenko <webknjaz@redhat.com>
2 years ago
Martin Krizek ddbad58428
Use FAs with inheritance only when applicable (#80026) (#80076)
... and set default value of an attribute on an object
only in NonInheritableFA.

Fixes #79777

ci_complete

(cherry picked from commit 6c3d2a4e51)
2 years ago
Sloane Hertel 1d3800a8d7
copy - fix check mode with remote_src=True (#78624) (#80176)
* Don't create dest directory in check mode

uncomment existing test

Fix checking for file attribute changes in check mode and add a test

(cherry picked from commit b7a0e0d792)
2 years ago
Matt Clay 86ebd55a3c [stable-2.14] ansible-test - Update git diff handling (#80202)
This change allows ansible-test to work with newer versions of git on AZP..
(cherry picked from commit bad8843124)

Co-authored-by: Matt Clay <matt@mystile.com>
2 years ago
Matt Clay 4461de15de [stable-2.14] Relocate the AZP entry point scripts (#80114)
Scripts previously under `test/utils/shippable/` are now under `.azure-pipelines/commands/` instead.
(cherry picked from commit f47bc03599)

Co-authored-by: Matt Clay <matt@mystile.com>
2 years ago
Matt Clay bea9a2acf7 [stable-2.14] ansible-test - Remove pointless comparison (#80168)
(cherry picked from commit 31658031ed)

Co-authored-by: Matt Clay <matt@mystile.com>
2 years ago
Matt Clay 4a3f5b7167 [stable-2.14] ansible-test - Fix vendoring support (#80074)
- Support loading of vendored Python packages.
- Exclude vendored Python packages from payloads.
(cherry picked from commit 6bfe6b899a)

Co-authored-by: Matt Clay <matt@mystile.com>
2 years ago
Matt Clay 7b21457d58 [stable-2.14] ansible-test - Show Python version before install (#80022)
Always indicate the Python version being used before installing requirements.
(cherry picked from commit 5e3db6e441)

Co-authored-by: Matt Clay <matt@mystile.com>
2 years ago
Matt Clay b1199e6a46 [stable-2.14] ansible-test - Allow target prefixes to use `_` (#80021)
Integration test target prefixes defined in a `tests/integration/target-prefixes.{group}` file can now contain an underscore (`_`) character.
(cherry picked from commit e6cffce0eb)

Co-authored-by: Matt Clay <matt@mystile.com>
2 years ago
Matt Clay d36f52614d
[stable-2.14] ansible-test - Improve code formatting (#79983) (#80206)
* ansible-test - Add blank lines after docstrings

* ansible-test - Preserve formatting of arg pairs

* ansible-test - Remove unused string

* ansible-test - Remove pointless dict() usage

* ansible-test - Clean up initial func arg indenting

* ansible-test - Clean up constructor arg indenting

* ansible-test - Clean up func arg wrapping

* ansible-test - Clean up comma and paren placement
(cherry picked from commit 715ab99462)
2 years ago
Matt Clay ff91a95ef1
[stable-2.14] ansible-test - Fix file permissions for delegation (#80203)
* [stable-2.14] ansible-test - Fix file permissions for delegation (#79932)

* ansible-test - Fix file permissions for delegation

* Set more restrictive permissions for SSH key

* Check all execute bits, not just owner

* Add a breaking_changes changelog entry
(cherry picked from commit c8c1402)

Co-authored-by: Matt Clay <matt@mystile.com>

* ansible-test - Fix collection delegation (#79947)

(cherry picked from commit 0793833847)

---------

Co-authored-by: Felix Fontein <felix@fontein.de>
2 years ago
Sviatoslav Sydorenko bfc26f55cc
[backport-2.14] 📦 Integrate manpage builds into PEP 517 build backend (#80129)
This patch creates a thin wrapper around the `setuptools`' PEP 517
build backend in-tree. It features an ability to request generating
the manpage files in the process of building a source distribution.
This toggle is implemented using the `config_settings` mechanism of
PEP 517.
One must explicitly pass it a CLI option to the build front-end to
trigger said behavior. The packagers are expected to use the
following call:

    python -m build --config-setting=--build-manpages

This option has no effect on building wheels.

🧪 The change includes integration tests

This test runs building and re-building sdists and wheels with and
without the `--build-manpages` config setting under the
oldest-supported and new `setuptools` pinned.

It is intended to preserve the interoperability of the packaging setup
across Python runtimes.

An extra smoke test also verifies that non PEP 517 interfaces remain functional.

PR #79606

Co-authored-by: Matt Clay <matt@mystile.com>
(cherry picked from commit 56036013cd)
2 years ago
Matt Clay 6be77608c6
[stable-2.14] ansible-test - Fix pylint error with old home dir (#80151) (#80152)
* [stable-2.14] ansible-test - Fix pylint error with old home dir (#80151)
(cherry picked from commit 27287b40c0)

Co-authored-by: Matt Clay <matt@mystile.com>

* ansible-test - Fix error with missing pylint home (#80155)

(cherry picked from commit 367d45facd)
2 years ago
Matt Clay d8d2005096
[stable-2.14] Fix MANIFEST.in includes (#80147) (#80148)
(cherry picked from commit 7c62cdeecd)
2 years ago
Matt Martz 0c2dd3eed3
[stable-2.14] Do not use hardcoded httpbin.org in uri tests (#80101) (#80102)
(cherry picked from commit 060a27f)
2 years ago
Brian Coca 58d66a7568
strategy fix invalid variables being registered (#79706) (#79818)
also added tests for normal and bad cases

(cherry picked from commit 281474e809)
2 years ago
Martin Krizek 02d9336b32
Make using blocks as handlers a parser error (#79993) (#80010)
Fixes #79968

(cherry picked from commit bd329dc543)
2 years ago
Matt Davis a082726ef2
[2.14] don't ignore templated _raw_params that k=v parser failed to parse (#79913) (#79964)
* don't ignore templated _raw_params that k=v parser failed to parse (#79913)

fixes #79862

(cherry picked from commit e1d298ed61)

* backport test change to runme.sh
2 years ago
Sloane Hertel c0395c486a
fix installing collections from git repos that contain MANIFEST.json (#79808) (#79826)
* add null 'manifest' key to metadata for git repo collections containing MANIFEST.json

changelog

* set to Sentinel instead of None

* Test installing a collection in a git repo that contains a MANIFEST.json

* fix test

* Update changelogs/fragments/ansible-galaxy-install-git-src-manifest.yml

(cherry picked from commit 321848e98d)
2 years ago
Martin Krizek 65366f663d
Fix conditionally notified include handlers (#79804) (#79807)
Fixes #79776

(cherry picked from commit 10eda5801a)
2 years ago
Matt Clay b2f362e6f1 [stable-2.14] ansible-test - Support Podman 4.4.0+
(cherry picked from commit 67d49734f7)

Co-authored-by: Matt Clay <matt@mystile.com>
2 years ago
Matt Clay 9e507faea5
[stable-2.14] ansible-test - Clean up indentation and spaces (#79980) (#79982)
(cherry picked from commit 58d84933fc)
2 years ago
Felix Fontein 8740fbd7cb
Bump acme test container. (#79783) (#79816)
(cherry picked from commit 5fb8bc3ddb)
2 years ago
Matt Clay 4fe7aae21d
[stable-2.14] ansible-test - Specify config path in plugin error (#79881) (#79977)
(cherry picked from commit d48d1c23df)
2 years ago
Matt Clay 7027806a77
[stable-2.14] ansible-test - Fix various type hinting issues. (#79798) (#79976)
* ansible-test - Add missing type hints.

* ansible-test - Remove redundant type hints.

* ansible-test - Fix return type annotations.

* ansible-test - Add assert, casts to assist mypy.

* ansible-test - Fix incorrect type hints.

* ansible-test - Remove no-op code.

* ansible-test - Fix incorrect types.

* ansible-test - Fix method signature mismatch.

(cherry picked from commit c9f20aedc0)
2 years ago
Matt Clay 6d53f61f9e
[stable-2.14] ansible-test - Remove obsolete DirectoryTarget. (#79975)
This code has been unused since at least the 2.9 release.

(cherry picked from commit 5f58015527)
2 years ago
Matt Clay 6adea5fa5c
[stable-2.14] ansible-test - fix warning to include image name (#79560) (#79973)
(cherry picked from commit 0a12d8a5bc)

Co-authored-by: Martin Krizek <martin.krizek@gmail.com>
2 years ago
Matt Clay 50b6d3515c
[stable-2.14] ansible-test - Avoid direct use of `errno`. (#79972)
Error handling on Python 3.x no longer requires the use of `errno` to identify specific errors.

(cherry picked from commit f9715f436c)
2 years ago
Martin Krizek 83db3015e9
Fix traceback in template action with ANSIBLE_DEBUG=1 (#79764) (#79775)
Fixes #79763

(cherry picked from commit 4f5ed24972)
2 years ago
Felix Fontein 522bdb8358
Argument spec alias handling: actually report deprecated aliases in suboptions, and fix warning message in suboptions when two aliases of the same option are used (#79740) (#79770)
* Normalize deprecation records.

* Fix alias deprecations in suboptions.

* Report in which option an alias warning happened for suboptions.

* Add deprecation tests for suboptions.

* Also test deprecation in list of dicts.

* Adjust unit tests for toplevel alias deprecation field name change.

(cherry picked from commit 8a7185c224)
2 years ago
Felix Fontein 165557df11
[2.14] fix role argument spec error for invalid suboptions & fix reporting of deprecated arguments for modules (#79738)
* fix role argument spec error for invalid suboptions (#76578)

fixes https://github.com/ansible/ansible/issues/75536

(cherry picked from commit b5b239fd71)

* Fix reporting of deprecated arguments for modules. (#79681)

(cherry picked from commit 1a47a21b65)

Co-authored-by: Sloane Hertel <19572925+s-hertel@users.noreply.github.com>
2 years ago
Matt Martz 014a1a5715
[stable-2.14] Ensure we are passing ciphers to all url_get calls (#79718) (#79727)
* Ensure we are passing ciphers to all url_get calls. Fixes #79717

* Add clog frag

* Fix tests
(cherry picked from commit 2143bcd)

Co-authored-by: Matt Martz <matt@sivel.net>
2 years ago
Sloane Hertel c83669a83e
ansible-galaxy - fix turning off the ConcreteArtifactManager's validate certs at the global level (#79561) (#79696)
Fix ignoring certs when downloading tarballs

Fix ignoring certs when downloading a collection from a specific source that isn't in the configured servers list

(cherry picked from commit acbf4cc60e)
2 years ago
Martin Krizek c297ee9b5d
Correctly count rescued tasks in play stats (#79724) (#79728)
Fixes #79711

ci_complete

(cherry picked from commit e38b3e64fd)
2 years ago
Jordan Borean 8e9834fde5 ansible-test - fix ps argspec check inside cmdlet (#79699)
* ansible-test - fix ps argspec check inside cmdlet

* Added error condition test

* Fix sanity problem

(cherry picked from commit ee33be9484)
2 years ago
Evgeni Golov a398724a31 [stable-2.14] validate-modules: don't fail on invalid YAML (#79682)
* validate-modules: don't fail on invalid YAML

When validate-modules encounters invalid YAML (e.g. in the EXAMPLES
section), it tries to reformat the exception to include the line number
in the Python file instead of the line number of the embedded YAML
document. However, PyYAML doesn't allow modification of the Mark object
(anymore) which leads to a new exception being raised, instead of
reporting the original exception.

As the original exception is not needed in other places anymore, we
don't have to modify it at all and can just compute the right line
number when reporting the error via ansible-test.

Fixes: #75837

* Add test for invalid module doc YAML syntax.

Co-authored-by: Matt Clay <matt@mystile.com>
(cherry picked from commit a7111c4dbb)

Co-authored-by: Evgeni Golov <evgeni@golov.de>
2 years ago
Matt Clay b6ded6209e [stable-2.14] Fix EPEL setup for integration tests on RHEL 7
(cherry picked from commit 1243d2ace0)

Co-authored-by: Matt Clay <matt@mystile.com>
2 years ago
Matt Clay acc8c3ccf8 [stable-2.14] ansible-test - Improve container startup handling.
Also improve the ansible-test-container integration test:

 - Add coverage for the no-probe code path.
 - Add work-arounds for centos6 containers (to support backporting).
 - Avoid systemd debug when the container doesn't use cgroup.
(cherry picked from commit 04fc98c794)

Co-authored-by: Matt Clay <matt@mystile.com>
2 years ago
Matt Clay 6a07424b36 [stable-2.14] Add more retries to ansible-test-container test.
(cherry picked from commit f6c0e22f98)

Co-authored-by: Matt Clay <matt@mystile.com>
2 years ago
Matt Clay 6ebb1324d4 [stable-2.14] ansible-test - Support RSA SHA-1 for SSH clients.
(cherry picked from commit 75b60b17ee)

Co-authored-by: Matt Clay <matt@mystile.com>
2 years ago
Matt Clay 240156ff67 [stable-2.14] ansible-test - Fix `--prime-containers` and `--explain` (#79581)
* Remove unused code.
* Fix explain errors.
* Fix `--prime-containers` with docker on cgroup v2.
(cherry picked from commit da3b1d3f50)

Co-authored-by: Matt Clay <matt@mystile.com>
2 years ago
Matt Clay 578c96b854 [stable-2.14] ansible-test - Fix target PyPI proxy config.
(cherry picked from commit dcc08eec35)

Co-authored-by: Matt Clay <matt@mystile.com>
2 years ago
sbettid 066054f1f2
[stable-2.14] Fix file touch check mode result (#79360) (#79422) (#79525)
* Fix file touch check mode result (#79360) (#79422)

Fixes #79360

(cherry picked from commit 3936b5c471)

* Rename changelog fragment according to PR number
2 years ago
Brian Coca d40213c32c
Removed sorting to preserve original order (#74839) (#79517)
updated tests to reflect new order

(cherry picked from commit 5b51b560d0)
2 years ago
Matt Clay 5e2806b502
[stable-2.14] ansible-test - Fix completion error in Python 3.11. (#79500)
(cherry picked from commit 38fe342)

Co-authored-by: Matt Clay <matt@mystile.com>
2 years ago
Sviatoslav Sydorenko 022202056e
[backport][2.14][PRs #78402 #79289] Enable the `reboot` integration test in CI (#79490)
* Enable the `reboot` integration test in CI

Co-Authored-By: Matt Clay <matt@mystile.com>
(cherry picked from commit bb7ad0f0d8)

* [CI] Move running `reboot` integration test to group 2

PR #79289, follow-up for #78402.

It was breaking the integration-aliases sanity test, but only
became apparent post-merge. This patch fixes that.

(cherry picked from commit 26a4775611)

Co-authored-by: Sloane Hertel <19572925+s-hertel@users.noreply.github.com>
2 years ago
Matt Clay 3ae796bdcf
[stable-2.14] ansible-test - Improve container management. (#78550) (#79507)
* [stable-2.14] ansible-test - Improve container management. (#78550)

See changelogs/fragments/ansible-test-container-management.yml for details..
(cherry picked from commit cda16cc5e9)

Co-authored-by: Matt Clay <matt@mystile.com>

* ansible-test - Fix container detection. (#79530)

(cherry picked from commit 80d2f8da02)
2 years ago
Matt Davis 047affbdc5
Prevent stdio deadlock in forked children (#79522) (#79539)
* background threads writing to stdout/stderr can cause children to deadlock if a thread in the parent holds the internal lock on the BufferedWriter wrapper
* prevent writes to std handles during fork by monkeypatching stdout/stderr during display startup to require a mutex lock with fork(); this ensures no background threads can hold the lock during a fork operation
* add integration test that fails reliably on Linux without this fix

(cherry picked from commit 1424484be0)
2 years ago
Matt Clay f240f69508 [stable-2.14] Handle line wraps in jinja_plugins test.
(cherry picked from commit 31f95e201a)

Co-authored-by: Matt Clay <matt@mystile.com>
2 years ago
Matt Clay 3bcb4f267d [stable-2.14] Don't use color in jinja_plugins test.
This should prevent color codes from interfering with string matches.
(cherry picked from commit 31f9d60b8d)

Co-authored-by: Matt Clay <matt@mystile.com>
2 years ago
Matt Clay 713f5c5ae8 [stable-2.14] ansible-test - Improve pylint command consistency. (#78896)
* ansible-test - Improve pylint command consistency.

Co-authored-by: Sviatoslav Sydorenko <wk.cvs.github@sydorenko.org.ua>
(cherry picked from commit bc274f5)

Co-authored-by: Matt Clay <matt@mystile.com>
2 years ago
Brian Coca 217eaf1e68
mention acl in permissions errors (#79209) (#79250)
as chmod/mode is not the only thing we attempt and Ubuntu not shipping acl
  in newer versions can lead to some confusion

  fixes #79146

(cherry picked from commit 0f18ddca9f)
2 years ago
Martin Krizek c5065264c2
2.14: jinja2_native: preserve quotes in strings (#79119) (#79144)
* jinja2_native: preserve quotes in strings (#79119)

Fixes #79083

(cherry picked from commit d34b578685)

* Fix test for jinja2_native preserve quotes (#79131)

Fixes https://github.com/ansible/ansible/pull/79119#discussion_r993752129

(cherry picked from commit 3a6eca6670)
2 years ago
Sloane Hertel 59f3c0238b
[2.14] ansible-galaxy - fix unnecessary api check when installing role (#79142)
* ansible-galaxy install - fix unnecessary api check when installing a role from git repo (#79090)

* delay server api evaluation until a GalaxyRole needs to make an api call for info, list, and install

(cherry picked from commit cb2e434dd2)

* Fix isinstance check (#79159)

Use GalaxyAPI for isinstance check instead of RoleDistributionServer, since the latter is defined in __main__ sometimes (when running integration tests or ansible-galaxy from source) and importing from ansible.cli.galaxy won't reference the same object.

(cherry picked from commit 89d682464b)
2 years ago
Brian Coca ffcdcef21c
copy, avoid moving non temp remote 'non' files (#79102) (#79154)
* copy, avoid moving non temp remote files that are not dirs/files
fix tests

(cherry picked from commit f66016df0e)
2 years ago
Sviatoslav Sydorenko 0f3a1d3c82
[2.14] Log `runme.sh` execution in integration tests (#79282)
* Log `runme.sh` execution in integration tests (#79263)

* Log `runme.sh` execution in integration tests

This patch adds `set -x` where it's missing in the integration tests.
It also enables `pipefail` in `runme.sh` scripts that use pipes.

* Add a change note for PR #79263

(cherry picked from commit 6674c43edd)

* Delete a bad PR #79263 change note

(cherry picked from commit 9cfb3f73e8)
2 years ago
Matt Clay edbd88d3f1 [stable-2.14] ansible-test - Fix and update documentation links.
(cherry picked from commit 938c0fa944)

Co-authored-by: Matt Clay <matt@mystile.com>
2 years ago
Matt Clay 4653d1f4a0 ansible-test - Update default container. 2 years ago
Sandra McCann a023813bd1
Bump antsibull-docs version from 1.6.1 to 1.7.0. (#79071) (#79231)
(cherry picked from commit 74b80c3193)

Co-authored-by: Felix Fontein <felix@fontein.de>
2 years ago
Matt Clay b7f9d839e0 ansible-test - Update base and default containers. 2 years ago
Matt Clay 41159432d1 [stable-2.14] Fix ansible-test-git test for newer git versions.
The latest versions of `git` include a fix for CVE-2022-39253. The fix blocks the file protocol by default.

See: 45c9f05c44/Documentation/RelNotes/2.30.6.txt
(cherry picked from commit 4202acb41b)

Co-authored-by: Matt Clay <matt@mystile.com>
2 years ago
Matt Clay 418b92b323 [stable-2.14] ansible-test - Fix pylint support on Python 3.11.
(cherry picked from commit 645b6b8581)

Co-authored-by: Matt Clay <matt@mystile.com>
2 years ago
Sviatoslav Sydorenko 51c0d50631 [stable-2.14] Restrict `wheel` below v0.38.0 under Pythons < 3.7 (#79187)
* Restrict `wheel` below v0.38.0 under Pythons < 3.7

* Add a change note for PR #79187

* Update changelogs/fragments/79187--wheel-0.38.0.yml

Co-authored-by: Matt Clay <matt@mystile.com>

* Use constraints file when installing wheel.

Co-authored-by: Matt Clay <matt@mystile.com>
(cherry picked from commit a76bbb18a5)

Co-authored-by: Sviatoslav Sydorenko <wk.cvs.github@sydorenko.org.ua>
2 years ago
Matt Martz febf071d01
[stable-2.14] Don't assume column index for netmask and broadcast (#79121) (#79132)
* Don't assume column index for netmask and broadcast. Fixes #79117

* fix typo
(cherry picked from commit f53dbf9)

Co-authored-by: Matt Martz <matt@sivel.net>
2 years ago
Brian Coca 9c9a33904a
fix password lookup's use of f=v settings (#76551) (#79106)
* fix password lookup's  use of f=v settings (#76551)

update tests

(cherry picked from commit 5d253a1380)

* fix password unit tests (#79113)

(cherry picked from commit c4d6629bce)

Co-authored-by: Sloane Hertel <19572925+s-hertel@users.noreply.github.com>
2 years ago
Matt Clay c6511e3a5b [stable-2.14] ansible-test - Update pylint to 2.15.4.
(cherry picked from commit 14e7f05318)

Co-authored-by: Matt Clay <matt@mystile.com>
2 years ago
Matt Martz cd9ef334d0
[stable-2.14] Ensure that we do not squash keywords in validate (#79049) (#79062)
* [stable-2.14] Ensure that we do not squash keywords in validate (#79049)

* Ensure that we do not squash keywords in validate. Fixes #79021

* become_user: nobody should only apply to the test tasks, not the setup_test_user role

* Update how become_user is specified

* Add test to ensure keyword inheritance is working for become

* Add clog frag

* Cache fattributes to prevent re-calculation

* ci_complete

* Remove unnecessary getattr.
(cherry picked from commit 420564c5bc)

Co-authored-by: Matt Martz <matt@sivel.net>

* Remove unneeded merge conflict changes
2 years ago
Martin Krizek cd52ae459d
Fix using FQCN for flush_handlers (#79057) (#79061)
Fixes #79023

(cherry picked from commit e1daaae42a)
2 years ago
Brian Coca b5eba64882
Omit full fix (#79024)
* omit keyword should reset to context (#78917)

* omit keyword should reset to context

  ensure we use context/inheritance when calculating value,
  using default only when context is unavailable.

  fixes #75692

(cherry picked from commit 9650ddb11c)

* fixes to FA inheritance (#78990)

finalized applies to all field attributes
fix getting parent value
also remove unused/needed extend/prepend signature
moar testing

(cherry picked from commit ff6e4da36a)

* setup role needs it's own info
2 years ago
Felix Fontein fea62e7553
Do not crash templating when filter/test name is not a valid Ansible plugin name (#78913) (#79026)
* Do not crash templating when filter/test name is not a valid Ansible plugin name.
* Store and re-raise KeyError if there was one.

Co-authored-by: s-hertel <19572925+s-hertel@users.noreply.github.com>
(cherry picked from commit 6d0aeac1e1)
2 years ago
Matt Clay f46bbb2140 [stable-2.14] ansible-test - Update distro containers to 4.8.0.
The updated containers include coverage 6.5.0..
(cherry picked from commit 5b239acb77)

Co-authored-by: Matt Clay <matt@mystile.com>
2 years ago
Matt Clay 53bac70257
[stable-2.14] ansible-test - Update coverage to version 6.5.0. (#78945)
(cherry picked from commit 20c1252212)
2 years ago
Jordan Borean d15815c88d
Fix connection/become task loop settings (#78565) (#78935)
* Fix connection/become task loop settings

* Remove old code

(cherry picked from commit ba6da65a0f)
2 years ago
Jordan Borean 04fe7b374d
ansible-test validate-module - support sidecar docs (#78904) (#78933)
(cherry picked from commit be4807b712)
2 years ago
Sandra McCann 923f952d6b
Upgrade antsibull-docs to 1.6.1 (#78872) (#78929)
* Bump antsibull-docs version to 1.6.0 to fully support filter docs.

* known_good_reqs.txt no longer exists.

* Bump version to 1.6.1.

(cherry picked from commit d93883645c)

Co-authored-by: Felix Fontein <felix@fontein.de>
2 years ago
sbettid 0747c5c859
[stable 2.14] Fix known host changed status when removing non-existing key #78598 (#78881)
* Fix known_hosts changed status when removing non-existing key (#78748)

* Ensure no change is reported when removing missing key for host with other keys

Co-authored-by: Matt Martz <matt@sivel.net>

* Rename changelog fragment for fix known hosts changed status cherry pick

* Rename changelog according to new PR number

Co-authored-by: Matt Martz <matt@sivel.net>
2 years ago
Matt Clay 4655fe6d8b [stable-2.14] ansible-test - Fix integration test target filter. (#78862)
- Allow disabled, unsupported, unstable and destructive integration test targets to be selected using their respective prefixes.
- Allow unstable tests to run when targeted changes are made and the ``--allow-unstable-changed`` option is specified (resolves https://github.com/ansible/ansible/issues/74213).
(cherry picked from commit d3d7785472)

Co-authored-by: Matt Clay <matt@mystile.com>
2 years ago
Matt Clay 7aff371ba5
ansible-test - Fix default container version. (#78854) 2 years ago
Matt Clay 38f706a2a3
ansible-test - Update base and default containers. (#78847) 2 years ago
Matt Martz eb35cf9bb7
[stable-2.14] Don't request repo updates when only testing modes (#78843) (#78848)
(cherry picked from commit 2542048)

Co-authored-by: Matt Martz <matt@sivel.net>
2 years ago
Matt Martz 900010571d
[stable-2.14] Add `use_rsa_sha2_algorithms` option for paramiko (#78789) (#78842)
Fixes #76737
Fixes #77673

Co-authored-by: Matt Clay <matt@mystile.com>
(cherry picked from commit 76b7466)

Co-authored-by: Matt Martz <matt@sivel.net>
2 years ago
Matt Clay 85dba943ab
[stable-2.14] ansible-test - Update Python 3.11 support. (#78840) (#78841)
- Update sanity test requirements to fully support Python 3.11.
- Make Python 3.11 the default in the base and default test containers.

(cherry picked from commit 4d25233ece)
2 years ago
Brian Coca b1ff0f4ebc
vault secrets file, keep context when symlink (#78734)
* vault secrets file, keep context when symlink

	fixes #18319

Co-authored-by: Sloane Hertel <19572925+s-hertel@users.noreply.github.com>
2 years ago
Matt Clay e5e87a3927
ansible-test - Update pylint to 2.15.3. (#78811) 2 years ago
Sloane Hertel a02e22e902
Add --offline option to 'ansible-galaxy collection install' (#78678)
* Add --offline option to 'ansible-galaxy collection install' to prevent querying distribution servers

This allows installing/upgrading individual tarfiles to have dependency resolution.
Previously needed to be done manually with --no-deps or else all collections and dependencies needed to be included in the requirements.

Co-authored-by: Sviatoslav Sydorenko <wk.cvs.github@sydorenko.org.ua>
2 years ago
Ruediger Pluem 1d410ca700
Fix local facts unreadable (#76095)
* Catch exceptions during stat calls

If such an exception is not caught it causes the complete
local facts gathering to fail.
2 years ago
Markus Opolka 616ad883ad
Add OSMC to Debian OS_FAMILY_MAP (#78778)
* Add OSMC to Debian OS_FAMILY_MAP

 - os_family fact of the Debian-based OSMC distribution was not detected correctly

* tweak changelog

Co-authored-by: Matt Davis <6775756+nitzmahone@users.noreply.github.com>
2 years ago
Sloane Hertel f26f3325ba
apt - fix module short-circuiting when a package is not installed and only_upgrade is True (#78790) 2 years ago
Matt Clay 7683c0ae54
ansible-test - Update base and default containers. (#78774) 2 years ago
Sloane Hertel 4b45b4b09d
apt - fix failure when package is not installed and only_upgrade=True (#78781)
* apt - fix module failure when package is not installed and only_upgrade is True

* changelog
2 years ago
Sloane Hertel 86b86398f0
add ansible_name/ansible_aliases attrs to plugin objects (#78700)
*  new _fqcn attribute to plugin objects
* unbreak plugins in subdirs
* Fix inadventent changes to _load_name and use existing vars
* add plugin aliases and name property, and replace plugin._load_name where incorrect
* Fix listing plugin names

Fix listing legacy and builtin together
test deprecated plugin documentation
fix doc extensions
remove sometimes inaccurate _load_name handling from plugin.name

* Add tests for REJECT_EXTS and doc extensions

Fix unpredictable collection redirects so non-fqcns in the redirect list are guaranteed to be legacy (instead of determined by the collections keyword)

Move aliases and name properties to _update_object so all plugin types, including doc fragments, can use them

* make legacy plugin names internally consistent
* rename attributes to ansible_name and ansible_aliases
2 years ago