Commit Graph

50900 Commits (c36acc9eaaf398089a85c50117e4d944341e8fbb)
 

Author SHA1 Message Date
Matt Clay 3c2e8b99be
Fix ansible-test handling of user-defined docker networks. (#72256)
* Fix ansible-test docker container detection.

* Attach test containers to the correct network.

* Do not assume `localhost` for accesing Docker.

* Look for containers on current network.

* Always map /var/run/docker.sock into containers.

This fixes issues when using a remote Docker host.

* Support container IP lookup from networks list.

* Fix container network attachment.

* Remove redundant container detection messages.

* Limit DOCKER_HOST parsing to TCP.

* Restore docker socket existence check.

The check is skipped if the docker hostname is not localhost.

* Correct changelog entry.
4 years ago
Felix Fontein 1489bf9190
Adds argspec tests for required, required_one_of and required_by (#72245)
* Improve variable names.

* Add test for required.

* Add test for required_one_of.

* Add test for required_by.
4 years ago
Abhijeet Kasurde fe65144a4a
vmware: Using env variable for custom SSL path (#72273)
When validate_certs is True and user has custom SSL
certificate path, user can use ``REQUESTS_CA_PATH``
in ``environment`` parameter of task to specify this path.

Fixes: https://github.com/ansible-collections/community.vmware/issues/49

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
4 years ago
Ruediger Pluem e64ba97e8a
Fix the reversed order of return values (#72088)
* Fix the reversed order of return values

AnsibleModule.run_command returns a tuple of return code, stdout and stderr.
The module main function of the user module expects user.create_user to
return a tuple of return code, stdout and stderr.
Fix the locations where stdout and stderr got reversed.

* Fix another missed occurance

* Add changelog

* Fix further reversed order of return values occurrences

Followup to 72c3ba62c8e2606a6a35d51075fba29ce5faf34e:
Fix further reversed order of return values occurrences.
4 years ago
Nathan Scott c20329a0f6
Update migrating_roles.rst (#72260)
Fix a typo in the sample spec file Source0 line
4 years ago
Sandra McCann 3ece57c01a
remove ansibleFest banner (#72253) 4 years ago
Rick Elrod 69e510e767
[virt facts] recognize containerd as a container (#72210)
Change:
- containerd is now recognized as container tech

Test Plan:
- Tested with Docker inside Github Actions in a private repo:

        "ansible_virtualization_role": "guest",
        "ansible_virtualization_tech_guest": [
            "containerd",
            "container",
            "VirtualPC"
        ],
        "ansible_virtualization_tech_host": [],
        "ansible_virtualization_type": "containerd",

Tickets:
- Fixes #66304 because this is what docker containers show up as
  in Github Actions.

Signed-off-by: Rick Elrod <rick@elrod.me>
4 years ago
Jaime Hablutzel afba5c2852
Miscellaneous fixes in user_guide/intro_inventory.rst docs (#72202)
* Fixing missing hosts entry under the group dict.

* Added missing 'vars:' key

* Reordering arguments for consistency with the format displayed by "ansible-playbook --help"

* Fixing contradictory text
4 years ago
Abhijeet Kasurde 02658d7bf8
k8s: Scenario guides (#72095)
* Start Kubernetes Scenario guides for users
* K8S inventory scenario guide

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
4 years ago
Ronald Eddy Jr d18901dd4a
Update HTTP -> HTTPS (#72244)
Co-authored-by: Ronald Eddy Jr <ron@Ronalds-MacBook-Pro.local>
4 years ago
Jordan Borean c9fa1d0e7e
Fix race condition when creating async dir (#72069)
* Fix race condition when creating async dir

* Simplify exception wrapper

* Remove var used for testing
4 years ago
Toshio Kuratomi 618d1a3871
Document security concern for users setting the system_tmpdirs shell plugin config (#72213) 4 years ago
Matt Martz be5fc4e642
Ensure we call action_loader.get with collection_list (#72206)
* Ensure we call action_loader.get with collection_list. Fixes #72170

* Add tests and changelog

* Remove grep, do assertion in playbook. ci_complete

* Skip old jinja2 versions

* ci_complete

* dedupe
4 years ago
Rick Elrod 9ddb1d76af
[tests/dnf] work around dnf packaging issue (#72249)
Change:
- In this test we end up upgrading dnf (and python3-dnf) so that we can
  test its new logging behavior. However, the latest Fedora 32 dnf had a
  packaging issue which caused it to not pull in the latest
  python3-libdnf. This is fixed, but not synced out to mirrors yet.
  Fixing it in this test will get CI passing again in the meanwhile.

Test Plan:
- CI

Tickets:
- https://bugzilla.redhat.com/show_bug.cgi?id=1887502

Signed-off-by: Rick Elrod <rick@elrod.me>
4 years ago
Adam Leskis 39d6c5ef7a
fix simple typos (#72219) 4 years ago
Brian Coca 5ec53f9db8
make collection callbacks follow normal flow (#59932)
make collections whitelist follow normal flow

* fixes missing set_options call and adhoc and stdout processing rules
* avoid dupes
* fixed to handle redirects
* also updated tests with new and more accurate skip message
* fix callback tests for envs with cowsay installed
* lots MOAR comments on why the code is as it is, some todos to refactor in future

Co-authored-by: Matt Davis <nitzmahone@users.noreply.github.com>
4 years ago
Matt Martz a33cc191bd
Update 2.11 Roadmap to include dates and planned work (#72222)
* Update 2.11 Roadmap to include dates and planned work

* remove comma
4 years ago
Matt Clay 2ef4b7e07e Fix ansible-test Azure Pipelines container auth. 4 years ago
Justin Otherguy 8465f285cc
Update playbooks_strategies.rst (#72176)
beside the fact that naming the variable to specify the number of machines executed in *parallel* is named *serial* - the number of hosts chosen in this example is not optimal, either: 2x2 = 4; so - 3 hosts in 2 batches should clear things up a little
4 years ago
Ken Celenza b18e462bbb
Consistent Taxonomy (#72215)
Historically "these" have been called directives, attributes, and keywords. We've now settled on `keyword` (https://docs.ansible.com/ansible/latest/reference_appendices/playbooks_keywords.html). Update all documentation to reflect this term.
4 years ago
Rick Elrod 3b40c6f3b7
[config] coerce more to string when 'type: str' (#72172)
Change:
- When a plugin defines `type: str` on a parameter, treat more kinds of
  input as a string instead of whatever it is parsed as.

Test Plan:
- New unit tests
- CI

Signed-off-by: Rick Elrod <rick@elrod.me>
4 years ago
Toshio Kuratomi 6e7a40dd94
Update the porting guide for a new ansible version (#72211) 4 years ago
dberg1 cdf62edc65
service_facts: return service state information on AIX (#72073)
* service_facts: return service state information on AIX

AIX uses the System Resource Controller (SRC) to manage services.
See https://www.ibm.com/support/knowledgecenter/ssw_aix_72/osmanagement/sysrescon.htm
Use lssrc command on AIX to return service state information.


Co-authored-by: dberg1 <dberg1@github.com>
4 years ago
Jordan Borean caba47dd3f
Add support for GSSAPI/Kerberos to urls.py (#72113)
* Add support for GSSAPI/Kerberos to urls.py

* Test out changes with the latest test container

* Get remote hosts working

* Fix up httptester_krb5_password reader

* Fix tests for opensuse and macOS

* Hopefully last lot of testing changes

* Dont do CBT on macOS

* Fixes from review
4 years ago
Matt Martz c4acd41d6e
Ensure delegate vars calculation has correct loop context. Fixes #37132 (#71477) 4 years ago
Matt Martz 5d811fc551
Remove incidental_win_psexec (#71953)
* Explicit coverage to remove incidental_win_psexec

* rc=1 failed

* ci_complete ci_coverage

* Test rc!=0 without failed and until

* ci_complete ci_coverage

* Remove incidental_win_psexec

* Reduce delay

* ci_complete ci_coverage
4 years ago
Sandra McCann 7c1dd1c7fb
add link to jinja docs from templating section (#72205) 4 years ago
Sandra McCann c084bc160c
add details on how to get API token for Galaxy (#72203) 4 years ago
Florian Heiderich e673b8e4ec
fix typo (foward -> forward) (#72182) 4 years ago
Andrius Benokraitis 9382738f52
Update contributing_maintained_collections.rst (#72178)
##### SUMMARY
Adding Kubernetes.Core collection, editing vmware.vmware_rest a bit


##### ISSUE TYPE
- Docs Pull Request

+label: docsite_pr
4 years ago
Andrew Klychkov 30a651bca3
Docsite: update user_guide/playbooks_async (#72115) 4 years ago
Raphael Prosillo e119c2d2bf
Add The Bullhorn to the community communication page (#72125)
Update documentation on communication channels for Ansible.
4 years ago
Jens Heinrich 835752cc53
Update playbooks_vars_facts.rst (#72150)
Remove misleading typo, add a note on the mode of local facts

Co-authored-by: JensHeinrich <github.com/JensHeinrich>
4 years ago
Gonéri Le Bouder af7fd0f79d doc: use FQCN for vmware_rest examples
Use the collection name + the module name for clarity.
4 years ago
Amin Vakil bb2c96aacc
Fix subversion_pacakges name (#72138) 4 years ago
Matt Clay 5f76bd2af7 Support collection constraints in ansible-test.
This allows collections to specify requirements and constraints for packages that ansible-test has requirements or constraints for.
4 years ago
Matt Martz 2f8dbf673e
Remove incidental_zabbix_host (#72142)
* Add explicit apt tests for fnmatch and update_cache

* Add explicit apt_key tests for fetching key directly from url

* ci_complete ci_coverage

* Remove repo only by repo

* ci_complete ci_coverage

* Add apt cache update after apt_repository to show that the cache doesn't update

* ci_complete ci_coverage

* Add systemd tests for enabling and disabling a service

* ci_complete ci_coverage

* Remove incidental_zabbix_host

* ci_complete ci_coverage
4 years ago
Matt Martz cf0cd4b50b
Remove incidental_aws_codebuild (#72140)
* Remove incidental_aws_codebuild

* ci_complete ci_coverage
4 years ago
Sloane Hertel 102e429285
Add test to replace exclusive incidental_cloudformation coverage (#72137)
* Add intentional coverage for incidental_cloudformation

* Remove the incidental_cloudformation test target and the now unused supporting modules
4 years ago
Gonéri Le Bouder c72e2ee675
import of the vmware_rest documentation (#72090)
Co-authored-by: Jill R <4121322+jillr@users.noreply.github.com>
4 years ago
Jordan Borean 1ae3683d0c
Fix example to use correct shebang (#72129)
* Fix example to use correct shebang

* Fix other example modules as well

* Ignore shebang test
4 years ago
Matt Martz cfa41898c4
Add explicit coverage of argspec choices with strings that shadow YAML bools (#72122)
* Add explicit coverage of argspec choices with strings that shadow YAML bools

* ci_complete ci_coverage

* Remove incidental_ufw

* ci_complete ci_coverage
4 years ago
Ankit Sagar 865113aa29
Update user module documentation (#72109)
Co-authored-by: ankitsagar <ankitsagar15@gmail.com>
4 years ago
Matt Martz 50c8c87fe2
Add explicit coverage of suboptions=list without elements (#72108)
* Add explicit coverage of suboptions=list without elements

* ci_complete ci_coverage

* Remove incidental_vmware_guest_custom_attributes

* ci_complete ci_coverage
4 years ago
Felix Fontein aff78f4cbc
Fix various sanity errors in plugins (#71736)
* Fix various sanity errors in plugins.

* Revert callback_type -> type transform.

* Undo paramiko_ssh 'connection' change, since this discrepancy is hardcoded in the plugin loader.

* Standardize on name and type (for callbacks).

* Fix existing author entries.

* Add 'Unknown (!UNKNOWN)' as author when author is missing.

* These are actually parsed as integers in the code.

* Revert "Add 'Unknown (!UNKNOWN)' as author when author is missing."

This reverts commit 29d1438aca.
4 years ago
Sloane Hertel 960e4c0809
Add intentional coverage for incidental_ec2_instance (#72028)
* Add a test suite for module_utils.common.dict_transformations

* ci_complete

ci_coverage

Add a wait_for test using delegate_to

* Remove incidental_ec2_instance

* Remove unused test support modules

* Requested changes

ci_complete

ci_coverage

* Oops, put everything back to test coverage again

ci_complete

ci_coverage

* Remove incidental_ec2_instance tests and supporting modules
4 years ago
Abhijeet Kasurde 9ffa84cc1c
basic: Handle exception in default selector (#72101)
In Python 2.7, default selector raises IOError
instead of OSError. Fix handles this exception.

Fixes: #71704

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
4 years ago
Rick Elrod ebc91a9b93
[unarchive] work on older RHEL with group: <gid> (#72098)
Change:
- No longer fail due to old Fedora/RHEL and our failure to try to cast
  gids to integers before trying to pass them to getgrgid() before
  trying to use them.
- Add tests for user/mode for various unarchive formats.

Test Plan:
- New integration tests, ran against centos6 container

Tickets:
- Fixes #71903
4 years ago
Rick Elrod a90e37d017
[virt facts] identify KubeVirt properly (#72092)
Change:
- Make KubeVirt be identified as such, and with a guest role.
- This is a breaking change, since playbooks could be relying on the
  incorrect behavior previously.

Test Plan:
- Issue author

Tickets:
- Fixes #72001

Signed-off-by: Rick Elrod <rick@elrod.me>
4 years ago
Rick Elrod 0332046699
[ansible-test] attempt to work around podman (#72096)
Change:
- podman > 2 && < 2.2 does not support "images --format {{json .}}"
- podman also now outputs images JSON differently than docker
- Work around both of the above.

Test Plan:
- Tested with podman 2.0.6 in Fedora 31.

Signed-off-by: Rick Elrod <rick@elrod.me>
Co-authored-by: Sviatoslav Sydorenko <wk.cvs.github@sydorenko.org.ua>
4 years ago