Commit Graph

2192 Commits (87601969a3a9d9c793d3af6574aef0e8c15932c6)

Author SHA1 Message Date
Wojciech Wypior 95e59e7ee7 adds description to bigip snatpool (#58179) 5 years ago
Wojciech Wypior 3531bf3148 fixes issue with ssl protocols ordering (#58177) 5 years ago
Wojciech Wypior becca36c5e Added new module for remote user management (#58171) 5 years ago
Sumit Jaiswal 58d446e61a
PR to fix where ansible_net_model was not being populated (#58159)
* fix bug 57285

Signed-off-by: Sumit Jaiswal <sjaiswal@redhat.com>

* minor fix

Signed-off-by: Sumit Jaiswal <sjaiswal@redhat.com>

* adding TC fix related

Signed-off-by: Sumit Jaiswal <sjaiswal@redhat.com>

* fix shippable error

Signed-off-by: Sumit Jaiswal <sjaiswal@redhat.com>
5 years ago
markafarrell 43872d6b88 Fix netconf guess_network_os to use ssh_config if supplied. (#55199)
* feature: use network_os=auto to trigger network os guessing

* doc: add debug messages

* fix linting

* fix test_netconf_init default network_os is auto

* add documentation

* fix rst errors

* use init lexer

* Update docs/docsite/rst/network/user_guide/platform_netconf_enabled.rst

Co-Authored-By: Sandra McCann <samccann@redhat.com>

* Update docs/docsite/rst/network/user_guide/platform_netconf_enabled.rst

Co-Authored-By: Sandra McCann <samccann@redhat.com>

* Update docs/docsite/rst/network/user_guide/platform_netconf_enabled.rst

Co-Authored-By: Sandra McCann <samccann@redhat.com>

* Update docs/docsite/rst/network/user_guide/platform_netconf_enabled.rst

Co-Authored-By: Sandra McCann <samccann@redhat.com>

* Update docs/docsite/rst/network/user_guide/platform_netconf_enabled.rst

Co-Authored-By: Sandra McCann <samccann@redhat.com>

* Update docs/docsite/rst/network/user_guide/platform_netconf_enabled.rst

Co-Authored-By: Sandra McCann <samccann@redhat.com>

* Update docs/docsite/rst/network/user_guide/platform_netconf_enabled.rst

Co-Authored-By: Sandra McCann <samccann@redhat.com>

* Update lib/ansible/plugins/connection/netconf.py

Co-Authored-By: Sandra McCann <samccann@redhat.com>

* Update lib/ansible/plugins/connection/netconf.py

Co-Authored-By: Sandra McCann <samccann@redhat.com>

* Update lib/ansible/plugins/connection/netconf.py

Co-Authored-By: Sandra McCann <samccann@redhat.com>

* Update docs/docsite/rst/network/user_guide/platform_netconf_enabled.rst

Co-Authored-By: Sandra McCann <samccann@redhat.com>

* Update docs/docsite/rst/network/user_guide/platform_netconf_enabled.rst

Co-Authored-By: Sandra McCann <samccann@redhat.com>

* Update docs/docsite/rst/network/user_guide/platform_netconf_enabled.rst

Co-Authored-By: Sandra McCann <samccann@redhat.com>
5 years ago
Chris Van Heuveln 52c811c841 nxos_bgp_neighbor: Add bfd support (#56932)
* nxos_bgp_neighbor: Add bfd support

- Add support for bfd state in nxos_bgp_neighbor

- Feature Pull Request

- nxos_bgp_neighbor

- Tested on platforms: `N3K,N6K,N7K,N9K`

* bfd T/F now bfd enable/disable

* pep fix ws
5 years ago
Chris Van Heuveln 727a6b405a nxos_ospf_vrf: Add 'bfd' support (#57425)
* nxos_ospf_vrf: Add 'bfd' support

* Add default to bfd doc hdr

* bfd T/F now bfd enable/disable
5 years ago
Chris Van Heuveln 30830a4482 nxos_pim: Add bfd support (#56908)
* nxos_pim: Add bfd support

* Add integration sanity

* minor cleanup

* bfd T/F now bfd enable/disable
5 years ago
Andrey Klychkov 64d0559e9f Postgres module_utils: add get_connect_params + unit tests (#58067)
* add get_conn_params

* add get_conn_params: add to the modules
5 years ago
Rob feae35ab7e add IAM role assumption to aws_ec2 inventory (#41637)
* add IAM role assumption to aws_ec2 inventory
* Ensure inventory._options has necessary option keys populated since the plugin docs parser isn't accessible to unit tests yet
5 years ago
Guillaume Martinez ec7b18952b gitlab_runner: Fix idempotency when creating runner (#57833) 5 years ago
Abhijeet Kasurde cf623fa62f
Terraform: Fix unbound local error (#57044)
* Added Unit tests
* Fixed regression

Fixes: #56934

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
5 years ago
bobdoah 33d0d36eaa AWS: Fix KeyError in aws_secret lookup (#54792) 5 years ago
Mariusz Mazur 51add5aa79 kubevirt: enable/update tests + fix merge_dicts() (#57685)
* Actually run the unit tests and separate them into two files

* Re-add recursion to merge_dicts()

* Update tests to work with current code
5 years ago
Chris Van Heuveln 205f6b1699 nxos_pim_interface: Add 'bfd' support (#57133)
* nxos_pim_interface: Add 'bfd' support

* PEP fixes

* fix copyright date

* bfd states changed from T/F to enable/disable/default
5 years ago
Enno Gröper 1ed7a654ba Improve testing of FactCache (#55739)
* Improve testing of FactCache
5 years ago
Sloane Hertel 598a058afe
[FactCache] define first_order_merge method (#55781)
* Add first_order_merge method

Add test for updating a key that already exists

* changelog
5 years ago
Anton Nikulin 4fa93d5b9b FTD configuration module: fix a bug with response parsing (#57480)
* Update dependence's name to firepower-kickstart

* Check response type before getting attributes

* Add unit test for construct_ansible_facts method

* Update error message
5 years ago
Sajna Shetty e25269e1b3 Adding dell ome device_info module (#53438)
* Adding device_facts module for contribution

* changes added for pylint error

* Updated code to solve ansible-test compile error

* Changes to avoide comile error added

* Review Comments changes update

* Avoided blank line

* pylint error changes

* Removed ansible_facts return in error case

* Updated description

* modules renamed

* changing from ansible_facts to device_info

* avoide pep8 error

* Updated sample output

* version changed to 2.9

* Changed Copyright license to BSD

* Changed 3-clause BSD license to 2-clause BSD

* Added unit test support for ome_device_info

* version change

* removed pylint error in unit test modules

* Avoid Sanity error for unit test modules

* updated version
5 years ago
Chris Archibald a58570f1bc na_ontap_snapshot_policy: Add ability to multiple schedules (#57366) 5 years ago
Chris Van Heuveln bd844bc11c nxos_interface_ospf: Add bfd support (#56807)
* nxos_interface_ospf: Add bfd support

Add support for `bfd` state in `nxos_interface_ospf`

- Feature Pull Request

`nxos_interface_ospf`

* Fix pep issues

* sanity loop: syntax

* bfd states changed from T/F to enable/disable/default

* doc hdr fixes
5 years ago
Matt Martz 728fce0c44 Perf improvement for Templar.is_template (#57489)
* Faster is_template
5 years ago
Chris Van Heuveln 7aa0d26fda nxos_bfd_global / NxosCmdRef initial commit (#56317)
* nxos_bfd_global: initial commit

This is an initial POC with just a few commands included.  The code has been written somewhat generically so that it can act as a best practices template for re-use in future modules. The implementation follows the yaml cmd_ref style to define each command's getter/setter/type/default. It supports platform-specific defaults.

The basic logic is to collect all relevant data in a `cmd_ref` dict and pass that around to various methods.

In the BFD case the devices don't provide JSON output so we have to screen-scrape with show runs.

BFD does not support present/absent states so there is no state param.

BFD has three different property types to handle. We can add add'l types as needed:

- int
- int_list (list of ints)
- str (needs support for 'no' keyword)

* Use get_capabilities to find platform type

* PR comment fixes, round 1

* Minor cleanups

* nxos_bfd_global: create NxosCmdRef in module_utils

This commit just takes the latest bfd global code and moves the bulk
of the code into new `class NxosCmdRef` in `module_utils/nxos/nxos.py`.

The only remaining code in `nxos_bfd_global.py` are the calls from `main()`.

* Add remaining command properties and documentation

* update argument_spec

* Add check for _exclude; add sanity test

* Add targets files for bfd

* Context and state absent updates

* Add dict support to cmd_ref

* Changed remaining list commands to dict usage

* Add idempotence check for dict

* Fix existing overwrite bug

* Move pattern matching logic into its own method

* add support for 'command: absent'

* Add `get_platform_shortname`; update BFD platform-specific settings

* /absent/deleted/

* /sh/show/ in prepare_nxos_tests

* add dict check to get_platform_shortname

* Add normalize_defaults()

* UTs for bfd_global

* support yaml for both py2/py3

* update cmd_ref doc header

* Fix python2.6 incompatibility with dict comprehensions

* Fix bfd_global doc header (yaml syntax fail)

* more shippable fixes

* yet more shippable fixes

* shippable: remove r' ' wrappers

* docfix - remove ':'

* escape regex ctl chars in yaml table

* remove extra blank lines

* Fix str(None) issue

* Command context updates

* import PY2,PY3 instead of import sys

* fix ordereddict import & parent_context

* try/except for yaml import

* fix import issue for ordereddict

* remove epdb

* nxosCmdRef_import_check() workaround for shippable

* fix PEP ws errors
5 years ago
Daniel Mellado Area 091bebcbf7 Add support for vlan update on ovs bridges (#57168)
This commit adds support for vlan update on openvswitch_bridge module.
5 years ago
Chris Archibald 57b3160f13 new feature (#57320) 5 years ago
Abhijeet Kasurde ee8a607cca ipaddr: Handle network address in ipmath (#57149)
* Updated testcase, documentation

Fixes: #54457

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
5 years ago
Chris Van Heuveln 6bb13bbb84 nxos_vlan: fix broken purge behavior (issue #57101) (#57229)
* nxos_vlan: fix broken purge behavior (issue #57101)

Symptoms/Analysis:
- `nxos_vlan` `purge: true` would fail when `purge` was trying to delete all unspecified vlans, including vlan 1.
- `nxos` devices do not allow removing vlan 1 and raise a cli exception error
- Previous fix #55144 caused a side effect when `purge` was used: vlan changes specified by `aggregate` were ignored; e.g.
 - vlan 4 is not present; playbook specifies `aggregate: { vlan: 4 }, purge: true`
 - results in proper purging but vlan 4 is not created

Solutions:
- ignore vlan 1 when purging
- remove the `not purge` check from state present logic

Added additional unit tests and integration tests.
Tested against all regression platforms.

* PEP fixes

* Add agg_show_vlan_brief.txt fixture

* Add warning for removing vlan 1

* change method name check
5 years ago
Andrey Klychkov 3e06013eb6 unittests for module_utils.common.removed.removed_module function (#57214) 5 years ago
rajaspachipulusu17 6b2688245e Pluribus Networks ipv6security raguard port module with UT (#57033)
* Pluribus Networks ipv6security raguard port module with UT

* Dox fix
5 years ago
rajaspachipulusu17 b8a317c527 Pluribus Networks vrouter packet relay module with UT (#57155)
* Pluribus Networks vrouter packet relay module with UT

* Doc fix
5 years ago
Matt Martz 8bd4e2a144 cert validation fixes - Attempt 2 (#55953)
* Attempt 2 of cert validation fixes

* Remove unused code

* Cleanup the tmp cert using atexit

* Fix linting issues

* Only add SSLValidationHandler when not HAS_SSLCONTEXT

* Catch value errors on non PEM certs

* Only catch NotImplementedError to avoid masking issues

* set self._context even with PyOpenSSLContext for conformity

* Fix error building

* normalize how we interact with the context we create

* Remove unused code

* Address test for py3.7 message difference

* open_url should pass the ca_path through

* Account for new error in url lookup test

* Guard some code behind whether or not we are validating certs

* Make _make_context public

* Move atexit.register up to where the tmp file is created
5 years ago
Sviatoslav Sydorenko 4c7fff315e
Fix module_utils.common.test_collections testsuite
PR #57181
5 years ago
Andrey Klychkov bf25889bfd test_postgres: fix typos 5 years ago
Andrey Klychkov 01ed7a489a Add unit tests for lib/ansible/module_utils/common/text/converters.py (#56915)
Co-Authored-By: Sviatoslav Sydorenko <wk.cvs.github@sydorenko.org.ua>
5 years ago
Felix Fontein 61b48778a7
Rename _facts -> _info (#57028) 5 years ago
rajaspachipulusu17 19a78bdc7b Pluribus Networks vrouter bgp module with unit test cases (#56434)
* Pluribus Networks vrouter bgp module with unit test cases
* Sanity fixes
5 years ago
Andrey Klychkov 86354ff1fb postgresql: remove depricated lib (#56641) 5 years ago
Wojciech Wypior fca2a4c68b adds ltm policy to bigip facts (#56926)
facts no longer return changed but queried status in results
5 years ago
Yury V. Zaytsev d88d71e4b1 route53_zone: return existing zone id in check mode (#56702)
* Returns zone ID for existing zone or `null`
* route53_zone: add module unit tests
* route53_zone: add compatibility with Python 2.6 to the unit tests
* route53_zone: address pycodestyle warning (add blank line)
5 years ago
Sam Doran 8f4f3750fe
Ensure uri module always returns status even on failure (#56240)
- Also return url and update docs for other values to indicate they are only returned on success.
- Add integration tests
- Use info variable for common return values
- Use -1 as default status rather than None. This is lines up with with existing code in urls.py
- Add unit tests to ensure status and url are returned on failure
5 years ago
Matt Martz 493cf817a9 Don't rely on netloc for determining hostname and port, just use hostname and port (#56270)
* Add changelog fragment
* Fix IPv6 address parsing for py2.6, and add tests
* make sure hostname isn't None
5 years ago
EvgenyF ea4842c0d3 Changing the license to Apache 2 5 years ago
Martin Krizek 34e9d6781b Templar: encapsulate _available_variables (#55435)
Ensure variables are reset between iterations
5 years ago
rajaspachipulusu17 8c29c78e22 Pluribus Networks vrouter loopback interface module with UT (#56450)
* Pluribus Networks vrouter loopback interface module with UT

* Sanity fixes
5 years ago
rajaspachipulusu17 7a615a9e0e Pluribus Network vrouter ospf module with unit tests (#56435)
* Pluribus Network vrouter ospf module with unit tests

* Sanity fix

* Doc fixes
5 years ago
Andrey Klychkov 386cef18ed module_utils.postgres: added unittests (#56381) 5 years ago
Andrey Klychkov f1b5836836 lib/ansible/parsing/ajson.py: added UNIT-tests (#56398) 5 years ago
anasbadaha 5a7bce1f8d Adding New Model onyx_qos for Configuring QoS on Onyx Switches (#55127)
* Adding New Model onyx_qos for Configuring QoS on Onyx Switches

Signed-off-by: Anas Badaha <anasb@mellanox.com>

* Fix Pep8 Failures in onyx_qos

Signed-off-by: Anas Badaha <anasb@mellanox.com>

* Fix Pep8 Failures phase 2

Signed-off-by: Anas Badaha <anasb@mellanox.com>

* Fix Samer's Comments on onyx_qos Module

Signed-off-by: Anas Badaha <anasb@mellanox.com>

* Fix Shippable Comments Phase 3

Signed-off-by: Anas Badaha <anasb@mellanox.com>

* Fix Current Version 2.9

Signed-off-by: Anas Badaha <anasb@mellanox.com>
5 years ago
James Tanner 940d58e1b3 Nullify improperly licensed test file 5 years ago
Gonéri Le Bouder cf78759f5b vmware_vm_facts: fix the support with regular ESXi
Ensure the module still work with the ESXi where CustomFieldsManager
does not exist.

From: https://www.vmware.com/support/developer/converter-sdk/conv60_apireference/vim.CustomFieldsManager.html

    The CustomFieldsManager object is used to add and remove custom fields to
    managed entities.
    The custom fields values set on managed entities are available through the
    customValue property and through the summary objects for VirtualMachine
    and HostSystem. They are not available directly through this managed object.
    This functionality is only available through VirtualCenter.

Fixes: #56071
5 years ago
anasbadaha 0f852f01c0 Adding Support For EVPN in BGP Module (#55503)
* Adding Support For EVPN in BGP Module

Signed-off-by: Anas Badaha <anasb@mellanox.com>

* Fix Pep8 Failures in onyx_bgp.py

Signed-off-by: Anas Badaha <anasb@mellanox.com>

* Fix Pep8 Failures in onyx_bgp.py Phase 2

Signed-off-by: Anas Badaha <anasb@mellanox.com>

* Fix Samer's Comments

Signed-off-by: Anas Badaha <anasb@mellanox.com>

* Remove file Variable

Signed-off-by: Anas Badaha <anasb@mellanox.com>
5 years ago
anasbadaha 0cb0fa918f Adding Support for NVE Protocol in onyx_protocol (#55513)
* Adding Support for NVE Protocol in onyx_protocol

Signed-off-by: Anas Badaha <anasb@mellanox.com>

* Fix Pep8 Failures in onyx_protocol.py

Signed-off-by: Anas Badaha <anasb@mellanox.com>
5 years ago
anasbadaha 031655def0 Adding Support for Traffic Class in Onyx Switches (#55577)
* Adding Support for Traffic Class in Onyx Switches

Signed-off-by: Anas Badaha <anasb@mellanox.com>

* Enhancing the code and elemenating code duplicate

Signed-off-by: Anas Badaha <anasb@mellanox.com>
5 years ago
vicmunoz ecdb616954 NetApp ONTAP module for manage ipspaces (#49821)
* NetApp ONTAP module for manage ipspaces

* fixes for ci_cd and code layout

* indentation fixes

* code style fixes

* fixing yamllint issue

* unit test for module na_ontap_ipspace

* fixing sanity tests

* change pytest.skip to pytest.mark.skip

* adding ansible version to 2.9
5 years ago
Felix Fontein bd47e64bc7 Hetzner failover IP: refactoring (#56203)
* Rename helper function.

* Extract hetzner.py module_utils.

* Rewrite docs.

* Add module docs fragment.

* Split up get_failover function.

* Add tests for new function.

* hetzner_pass -> hetzner_password

* Move common argspec to module_utils.
5 years ago
zengchen d8314e1a45 refactor moudule utils of hwc_utils.py (#55858)
* use navigate_value instead navigate_hash

* add async wait method

* update dict compare

* remove unuse methods

* not all modules have timeouts parameter

* navigate_value, the input data may be None
5 years ago
rajaspachipulusu17 458b473d06 Pluribus network prefix list module (#55686)
* Pluribus network prefix list module

* Doc fix and unit test fix

* Added default value with args spec change

* Sanity fix
5 years ago
Trishna Guha 2e8a3efccb
Revert nxos, ios, iosxr return_timestamps (#56206)
* Revert "nxos_command:run_commands results failure when commands array size >1 (#52670)"
This reverts commit 0df5b92af3.
* Revert "added timestamps to nxos_command module (#50261)"
This reverts commit e150943314.
* Revert "added timestamps to ios_command module (#50323)"
This reverts commit 2a432a093b.
* Revert "added response_timestamps to iosxr_command module (#50095)"
This reverts commit 2a0c356da9.
5 years ago
Trishna Guha 57e0567310
fix nxos_vlan mode idempotence bug (#55144)
* fix nxos_vlan mode idempotence bug

Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>

* Fix CI failure

Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
5 years ago
Felix Fontein ba9fee6c37 Hetzner failover IP module (#56103)
* First version of Hetzner failover IP module.

* Extend module.

* Add comments.

* Add basic unit tests.

* Add more tests.

* Tests for set_failover.
5 years ago
Anatoly Pugachev 6e73150244 refactor iscsi network facts module, remove external grep call, add unit test (#55643)
* remove external grep call and parse with python
* use function for repeated code
* use module.get_bin_path() for iscsiutil on HPUX
* some code opt for HPUX
* clean up non-module code, module being defined is a requirement for this code
* import get_bin_path() directly and use without module prefix
* Add integration tests for AIX and HP-UX
* add changelog fragment
* Apply suggestions from code review
Co-Authored-By: mator <matorola@gmail.com>
* Apply suggestions from code review #2
Co-Authored-By: Sam Doran <sdoran@redhat.com>
* Remove strict requirement on executable to exist for get_bin_path() as
it will allow facts gathering to continue without an error. Almost all
other files under facts do not have "required=True" (except 2 files,
which should be probably fixed). And check return value for
get_bin_path() , before run attempt.

* add check for AIX lsattr run_command return code
5 years ago
rajaspachipulusu17 5309d6c131 Pluribus networks fabric local module with UT (#55872)
* Pluribus networks fabric local module with UT

* Sanity fix

* Ansible doc standards

* Unit test fix
5 years ago
Anatoly Pugachev b9af6847c2 network facts, add unit test for FC WWN (#55848)
* use 'None' as return value for get_bin_path and set return code to non-zero on run_command error
5 years ago
Sam Doran b3ce3fc5eb
Restore ansible --version output (#55728)
* Add custom action class for version info
* Use args from CLI as prog for ArgumentParser object
* Make prog a required parameter of create_base_parser() and update all uses to pass in the newly required parameter.
* Add unit test for checking ansible --version
* Update other related unit tests
5 years ago
Matt Clay 272bb8da7a Fix test_postgresql dependency analysis. 5 years ago
Matt Martz 2732cde031
Support using importlib on py>=3 to avoid imp deprecation (#54883)
* Support using importlib on py>=3 to avoid imp deprecation

* Add changelog fragment

* importlib coverage for py3

* Ansiballz execute should use importlib too

* recursive module_utils finder should utilize importlib too

* don't be dumb

* Fix up units

* Clean up tests

* Prefer importlib.util in plugin loader when available

* insert the module into sys.modules

* 3 before 2 for consistency

* ci_complete

* Address importlib.util.find_spec returning None
5 years ago
Matt Martz db6cc60352
Migrate command line parsing to argparse (#50610)
* Start of migration to argparse

* various fixes and improvements

* Linting fixes

* Test fixes

* Fix vault_password_files

* Add PrependAction for argparse

* A bunch of additional tweak/fixes

* Fix ansible-config tests

* Fix man page generation

* linting fix

* More adhoc pattern fixes

* Add changelog fragment

* Add support for argcomplete

* Enable argcomplete global completion

* Rename PrependAction to PrependListAction to better describe what it does

* Add documentation for installing and configuring argcomplete

* Address rebase issues

* Fix display encoding for vault

* Fix line length

* Address rebase issues

* Handle rebase issues

* Use mutually exclusive group instead of handling manually

* Fix rebase issues

* Address rebase issue

* Update version added for argcomplete support

* -e must be given a value

* ci_complete
5 years ago
Alex Stephen e298de0986 GCP deprecations (#53355)
* gcdns_record deprecation

* gcdns_zone deprecation

* gcp_forwarding_rule deprecation

* gcp_url_map deprecation

* gcspanner deprecation

* gcp_healthcheck deprecation

* porting guide

* test failures

* forgot to rename

* deprecating

* porting guide changes

* unit test fixes

* changing ignores
5 years ago
Anatoly Pugachev de3bd8b791 extends linux cpuinfo test unit with sparc64 data (#55394)
* added debian sparc64 ldom cpuinfo

* updated linux data test unit with sparc64 cpuinfo
5 years ago
Matt Martz 9f83139dcb
Don't register tests as filters (#55332)
* Don't register tests as filters. Fixes #55319

* Remove tests for deprecated functionality

* Remove no-tests-as-filters sanity tests

* Remove docs too

* Revert "Remove docs too"

This reverts commit 7daf457a74.

* Make no-tests-as-filters doc an orphan
5 years ago
Anatoly Pugachev b28c73af62 Fixes solaris (sunos) uptime in ansible facts module (#54626)
* correct uptime on solaris by using system boot_time instead of snaptime
* add unit test
5 years ago
Toshio Kuratomi a1c8fc37e8 Remove modules which have ended their deprecation cycle
* Remove code but leave the metadata so that they can be listed as
  removed in documentation.
* Remove removed modules from validate-modules ignore
* Remove unittests for the removed nodules
* Remove links to removed modules and add list of removed moduels to the
  2.9 porting guide
5 years ago
Nathan Dines 5eb3117822 Added the OnFailure option to the AWS CloudFormation module (#52431)
* Added the OnFailure option to the AWS CloudFormation module

* Added unit tests for CloudFormation `on_create_failure`
5 years ago
Brian Coca e40832df84
become mixin is no more (#54002)
* become mixin is no more
  since sudo/su keywords are removed in 2.9 .. no need to keep this code around
 * also don't need test for code that is removed
 * made preprocess_data on base noop
   its not used by anything anymore, but kept for backwards compat since other methods of same name are used
5 years ago
anasbadaha 2cc91e26e0 Adding Support For Vxlan In Onyx Switches (#55081)
* Adding Support For Vxlan In Onyx Switches

Signed-off-by: Anas Badaha <anasb@mellanox.com>

* Fix Pep8 Failures in onyx_vxlan.py

Signed-off-by: Anas Badaha <anasb@mellanox.com>

* Fix Pep8 Failures in onyx_vxlan phase 2

Signed-off-by: Anas Badaha <anasb@mellanox.com>

* Fix Shippable failures

Signed-off-by: Anas Badaha <anasb@mellanox.com>

* Fix Samer's Comments on PR

Signed-off-by: Anas Badaha <anasb@mellanox.com>
5 years ago
Swartz, Nathan 5e3a7ec1f5 Improve netapp_e_volume module and add unit tests.
netapp_e_volume was refactored for maintainability and its documentation
was improved for better clarity.
5 years ago
anasbadaha 9bd060292e Adding New Model for Configure Buffer Pool on Onyx Switches (#55082)
* Adding New Model for Configure Buffer Pool on Onyx Switches

Signed-off-by: Anas Badaha <anasb@mellanox.com>

* Fix Pep8 Failures in onyx_buffer_pool.py

Signed-off-by: Anas Badaha <anasb@mellanox.com>
5 years ago
Chris Archibald e12846f540 Update na_ontap_export_policy_rule to allow multiple rules to be set at once. (#54801)
* update

* add unit tests
5 years ago
Chris Archibald c51f840faa Allow for multiple LIFS instead of 1 at a time (#54800)
* upload unit tests
5 years ago
Jordan Borean ebd4462c23
Fix tests for the psrp connection plugin (#55061) 5 years ago
Matt Martz fbf2d5d2f4
Don't pollute include_variables (#54687)
* Don't pollute include_variables. Fixes #51667. Fixes #54618.

* Rename include_variables to include_args, so we can make the distinction about what they are

* Track args and vars separately

* oops

* oops again

* linting fix

* Add test
5 years ago
Sam Doran 6761fc1475
Update distro unit test (#55003)
Remove test comparing output to platform.linux_distribution() since we are relying on distro.id() and are not concerned about matching the output of platform.linux_distribution()
6 years ago
Chris Archibald c6f12eea32 push fix (#54916) 6 years ago
Anil Kumar Muraleedharan f5d97205a0 The module fails on switchport. Check added to fix. (#54970) 6 years ago
Bruno Inec c637104078 Allow Netbox device modification (#53631)
* netbox_device: Allow device modification

* Add ability to update and existing device
* Allow check_mode
* Fail when device name is missing
* Fail when cannot resolve ID instead of taking ID 1 by default

* netbox_device: Add diff output

* netbox: Some refactoring

* Add diff output and check_mode to netbox_ip_address
* Deduplicate redundant code into netbox_utils

* netbox_utils: A few unit tests
6 years ago
Brian Coca bda541fa0d
fix missing attribs with dirct module execution (#53875)
* fix missing attribs with dirct module execution
* also make remote tmp handling smarter
 update tests
* set default if attrib does not exist
* add simple test
6 years ago
Claes Nästén 339f6cfcd1 NSO modules now work as expected with NSO 5.X (#54766)
Update NSO modules for NSO 5.0 which change how prefix mapping is made
as a single prefix can have multiple meanings depending on device
being managed
6 years ago
Federico87 48e83c39ba ASA network/service object-group module (#52925)
* add asa_og module

* add test

* fix pep8

* fix some sanity pylint

* fix import error order

* fix import

* replace cmd() method

* rename file and class

* add mock for connection

* fix commands in  replace test function

* fix lines list

* update unit test

* fix 'and' logic for port-object command

* restore previous unit test; fix pep8 and remove debug

* other unit tests

* Add state present, absent, replace

* Update doc; add default for state

* update unit test with state present/absent

* fix typo in unit test

* fix pep8 too many blank lines

* fix show run for service object ASA Ver 8.x

* Add description field; fix bug for state present and absent

* Re-designed module structure for network, service and port objects

* update integration test for new module structure

* fix pep8

* update EXAMPLES and RETURN

* update units tests

* fix module typos in unit test

* removed provider from examples

* fix missing comma in replace test

* fix module name and remove provider

* update license

* remove register; update license; change import order; chage def state

* remove shebang

* fix doc default state

* change import order

* Update year in banner

* fix integration test as set of tasks

* remove arg_spec

* remove extends_documentation_fragment: asa

* Update DOC, remove unused import, change import order
6 years ago
Chris Archibald ec03ddd336 Multiple fixs for na_ontap_user (#54610)
* Fix ontap user for 9.1

* fix bugs:

* update unit tests
6 years ago
Łukasz Szczęsny bcdd1dc951 pamd: fix idempotence issue when removing rules (#54105) 6 years ago
Vitalii Kostenko 2176b53a55 Add latest updates from FTD Ansible downstream repository. (#53638)
* Add latest updates from FTD Ansible downstream repository.
 - add a better implementation of the upsert operation;
 - add API version lookup functionality;
 - add filter which remove duplicated references from the list of references;
 - fix minor bugs.

* fix issues outlined by ansibot

* fix argument name for _check_enum_method
6 years ago
Wojciech Wypior 6a27e308dd BIGIP: deprecates TMOS v11.x support for GTM modules (#54543)
* deprecates TMOS v11 support for GTM modules

* correct version

* correct version
6 years ago
zhongjun2 5599b0484f cloud: huawei: Add new module hwc_network_vpc (#54102) 6 years ago
Evgeniy Krysanov a6a73594ec Add Bitbucket Pipelines SSH key pair module (#54241)
* Add module to manage Bitbucket Pipelines key pairs

* Rename module bitbucket_pipelines_ssh_key to bitbucket_pipeline_key_pair

* Update `version_added` documentation field

* Cosmetic changes

* Apply suggestions from code review

Co-Authored-By: catcombo <evgeniy.krysanov@gmail.com>
6 years ago
Yury V. Zaytsev c914df354b Add Bitbucket access key module (#54592)
* Add Bitbucket access key module

* Add Bitbucket access key tests

* Remove superseded `bitbucket_deploy_key` module

* Apply suggestions from code review
6 years ago
Evgeniy Krysanov 655d35cd06 Add Bitbucket Pipelines known host module (#54238)
* Add module to manage Bitbucket Pipelines "Known Hosts"

* Rename bitbucket_pipelines_known_host to bitbucket_pipeline_known_host

* Rename `hostname` module param to `name`

* Rename `public_key` module param to `key`

* Fix documentation `version_added` tag

* Remove suppression of deprecation warnings

* Added check availability of package `paramiko`

* Make `paramiko` package optional if `key` is present

* Apply suggestions from code review

Co-Authored-By: catcombo <evgeniy.krysanov@gmail.com>

* Add error messages for invalid username or repository

* Add detection of public key type for key passed as parameter

* Restore Python 2 compatibility

* Fix error message wording
6 years ago
Patryk D. Cichy 43514e9d93 Add a new CloudStack module - cs_traffic_type (#54451)
* Add get_physical_network to AnsibleCloudStack

* Add new module cs_traffic_type
6 years ago
Matt Davis f86345f777
Collection content loading (#52194)
* basic plugin loading working (with many hacks)

* task collections working

* play/block-level collection module/action working

* implement PEP302 loader

* implicit package support (no need for __init.py__ in collections)
* provides future options for secure loading of content that shouldn't execute inside controller (eg, actively ignore __init__.py on content/module paths)
* provide hook for synthetic collection setup (eg ansible.core pseudo-collection for specifying built-in plugins without legacy path, etc)

* synthetic package support

* ansible.core.plugins mapping works, others don't

* synthetic collections working for modules/actions

* fix direct-load legacy

* change base package name to ansible_collections

* note

* collection role loading

* expand paths from installed content root vars

* feature complete?

* rename ansible.core to ansible.builtin

* and various sanity fixes

* sanity tweaks

* unittest fixes

* less grabby error handler on has_plugin

* probably need to replace with a or harden callers

* fix win_ping test

* disable module test with explicit file extension; might be able to support in some scenarios, but can't see any other tests that verify that behavior...

* fix unicode conversion issues on py2

* attempt to keep things working-ish on py2.6

* python2.6 test fun round 2

* rename dirs/configs to "collections"

* add wrapper dir for content-adjacent

* fix pythoncheck to use localhost

* unicode tweaks, native/bytes string prefixing

* rename COLLECTION_PATHS to COLLECTIONS_PATHS

* switch to pathspec

* path handling cleanup

* change expensive `all` back to or chain

* unused import cleanup

* quotes tweak

* use wrapped iter/len in Jinja proxy

* var name expansion

* comment seemingly overcomplicated playbook_paths resolution

* drop unnecessary conditional nesting

* eliminate extraneous local

* zap superfluous validation function

* use slice for rolespec NS assembly

* misc naming/unicode fixes

* collection callback loader asks if valid FQ name instead of just '.'
* switch collection role resolution behavior to be internally `text` as much as possible

* misc fixmes

* to_native in exception constructor
* (slightly) detangle tuple accumulation mess in module_utils __init__ walker

* more misc fixmes

* tighten up action dispatch, add unqualified action test

* rename Collection mixin to CollectionSearch

* (attempt to) avoid potential confusion/conflict with builtin collections, etc

* stale fixmes

* tighten up pluginloader collections determination

* sanity test fixes

* ditch regex escape

* clarify comment

* update default collections paths config entry

* use PATH format instead of list

* skip integration tests on Python 2.6

ci_complete
6 years ago
Gonéri Le Bouder fc3064471b virt_net: idempotency of create/stop actions (#53276)
Currently, if we try to stop or start a network two time in a row, the
second call will fail. With this patch:

- we don't recreate a network, if it exists
- we only stop a network if it's active, and so we avoid an exception
  saying the network is not active

* test: mock libvirt

* add integration tests for virt_net

* test: enable virt_net test on RedHat 7 and 8

* ci: use the unsupported alias

* tests that require privileged mode are run in VM

* virt_net/create raise unexpected libvirt exception

* import mock from units.compat

* virt_net: do not call create() on "active" network

* virt_net func test: only clean up the libvirt packages

* test: virt_net: don't use assert_called()

* virt_net: add the destructive alias

* move the test in virt_net dir

* test/virt_net: clean up the network at the end
6 years ago
Anil Kumar Muraleedharan 82d26c8c93 Lenovo cnos vrf (#54188)
* Adding module cnos_vrf to manage VRF Configurations.

* Update cnos_vrf.py

* Adding Functional Tests, Unit Tests and Bug Fixes.

* Fixing discrepancy in description against sample

* Review comments incorporated

* Review comments 2 Done

* Update basic.yaml

* Update test_cnos_vrf.py

* Review comments 3
6 years ago