Commit Graph

5280 Commits (b9bff5e39a0fe104b1c05074744987ef9cab7e7a)

Author SHA1 Message Date
jamessemai 9e706a3ed4 win_security_policy: Allow setting a value to empty (#42051)
* win_security_policy: allow removing values (resolves #40869)

* Removing warning

* Adding test for remove policy setting

* Fixing string comparison

* Make idempotent

* Adding idempotency and diff test

* added changelog fragment

(cherry picked from commit dc32842573)
6 years ago
Nilashish Chakraborty 8b26e3899f Fix ios_vlan issue CP into 2.6 (#42665)
* Make ios_vlan identify vlans starting with 9 (#42247)

* Make ios_vlan identify vlans starting with 9

* Add unit test for vlan id start with 9

(cherry picked from commit 70e33ef92c)

* Added changelog for ios_vlan fix

* Fixed changelog Shippable errors

* Fix 2 for Shippable changelog errors
6 years ago
Matt Clay 4b17adaf66 Temporarily switch RHEL and Windows tests to AWS.
(cherry picked from commit 11d0eb04ce)
6 years ago
Matt Clay 7968a84e4b Fix openshift integration test requirements.
(cherry picked from commit 2fbc2abf86)
6 years ago
Matt Clay 0c504ce2c4 Remove unwanted containers at CI job start.
(cherry picked from commit 528de5b82f)
6 years ago
Trishna Guha edf933918d nxos and eos bugfix pick2.6 (#42291)
* fix nxos_vxlan_vtep_vni issue (#42183)

Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
(cherry picked from commit 981c9f6a79)

* nxos CI failures bugfix (#42240)

* fix nxos_portchannel and remove deprecated param in test

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

* fix _nxos_switchport CI failures

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

* fix nxapi nxos_command test

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

* remove unsupported param nxos_smoke test

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

* fix nxos_vxlan_vtep_vni

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

* syntax error

Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
(cherry picked from commit 805d13f287)

* Update eos_l2_interface.py (#42270)

(cherry picked from commit 51092c6ea5)

* add changelog

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

* Enforcing NXAPI default HTTP behavior (#41817)

* nxos_nxapi http default behavior

* Use nxos_nxapi module in prepare_nxos_tests

* Refactor nxos_nxapi configure test to use yaml block

* Extend nxos_nxapi https & http test cases

* Removed NXOS internal release naming

* Resolved ansibot sanity errors

* Fix typo in prepare_nxos_tests

* Address PR comments

* Shippable indicates this is no longer needed

* Add port change logic and testing

(cherry picked from commit db7300904d)

* update changelog

Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
6 years ago
Sam Doran 3bec68a3b3 Backport #42013 for 2.6 - linenfile empty regexp warning (#42204)
* Add warning when using an empty regexp in lineinfile (#42013)

* Revert "Account for empty string regexp in lineinfile (#41451)"

This reverts commit 4b5b4a760c.

* Use context managers for interacting with files

* Store line and regexp parameters in a variable

* Add warning when regexp is an empty string

* Remove '=' from error messages

* Update warning message and add changelog

* Add tests

* Improve warning message

Offer an equivalent regexp that won't trigger the warning.
Update tests to match new warning.

* Add porting guide entry for lineinfile change

# Conflicts:
#	docs/docsite/rst/porting_guides/porting_guide_2.7.rst
#	lib/ansible/modules/files/lineinfile.py
#	test/integration/targets/lineinfile/tasks/main.yml

* Add porting guide info
6 years ago
John R Barker 56cca2a312 Allow documentation of module options type (#42285)
* Allow documentation of module options

Pass through the `type` of a modules option so it's displayed on the
html module docs

* docs

(cherry picked from commit d962611528)
6 years ago
Jordan Borean 1024f53ffd Win group membership sid refactor 2.6 (#41990)
* Refactor/fix win_group_membership to use SIDs for internal comparisons (#40725)

* refactor win_group_membership to use SIDs for comparisons instead of name parsing

* carry over previous doc cleanup changes

* remove trailing whitespace from docs

(cherry picked from commit bcb49f2575)

* Added changelog fragment
6 years ago
Kevin Breit d2b447e8a1 Fixes idempotency check for partial configurations (#41941)
- Previous PR would overwrite new and existing values improperly

(cherry picked from commit 7ab3f755ce)
6 years ago
John R Barker f2af5e0053 Fix some broken links (#42079)
* Fix some broken links

* We now only serve via https
* redirects don't work with anchors, so update those links (devel/dev_guide)

(cherry picked from commit e9dbebfa57)
6 years ago
Sam Doran bd1ecd016b Backport #41767 for 2.6 - Skip if insertbefore is using BOF until later in the module (#41929)
* Skip if insertbefore BOF until later (#41767)

If a line match is found in the file and no regexp is specified, insertbefore would improperly try to add a line if set to BOF.

Add tests for this scenario.

(cherry picked from commit eaae1318f8)

* Add changelog fragment
6 years ago
Martin Krizek f9c17f6337 Fix rabbitmq_* integration tests (#41836)
(cherry picked from commit a8d4bf8642)
6 years ago
Zim Kalinowski 701d61531c Fix broken Azure dependencies in 2.6 (#41946)
* fixed requirements
* module fix
* updated test accordingly
* mysql & postgresl fixes
* upgraded databases
* removed test from ignore.txt
* updated mysql & postgresql tests
6 years ago
Jordan Borean 25ad5fa225 Stop displaying kinit pass input on a failure (#41882)
* Stop displaying kinit pass input on a failure

* Fixed up minor logic info and added tests

(cherry picked from commit 9b7b564d75)
6 years ago
Nilashish Chakraborty 7cb2486fad Fix vyos_vlan aggregate issue & added tests (#41638)
* Fix vyos_vlan aggregate issue & Added tests

* Fix #2 for vyos_vlan aggregate issue

(cherry picked from commit 837c216587)
6 years ago
Andrew Gaffney e3a1aef586 Fix wrong python keyword (followup to #36357) (#41067)
Also add tests around that code path
6 years ago
Brian Coca 88d0e2a04a fix minor issues with debug and item labels (#41331)
* fix minor issues with debug and item labels

 - no more `item=None`, we always have a label now
 - debug should only show expected information, either msg= or the var in var=
 - also fixed method name, deprecated misleading _get_item

(cherry picked from commit 27c43daab8)
6 years ago
Jordan Borean 9ce55f7e94 win_updates fix when win_updates is run with async (#41756)
(cherry picked from commit 11bd3fd318)
6 years ago
Kevin Breit 933ca5a41b Improved support for parameter testing and checks for org_id (#41517)
(cherry picked from commit cccaf951fa)
6 years ago
Matt Clay 3030625d1f Disable remaining failing rabbitmq_* tests.
(cherry picked from commit 5880404151)
6 years ago
Matt Clay 79a415d4a0 Disable failing rabbitmq_plugin test.
(cherry picked from commit 00ab12dca2)
6 years ago
Matt Clay ed5e619083 Temporarily disable gem test on osx.
Disabled due to lack of newer TLS version support on the test system.

(cherry picked from commit dce708e63e)
6 years ago
Markos Chandras f58780fb28 facts: suse: Fix major version detection for SUSE (#41416)
When parsing the distribution files such as /etc/os-release, we extract
the full distribution version but not the major version. As such, the
ansible_distribution_major_version ends up being 'NA' whereas the
ansible_distribution_version contains the full version.

Before this patch we get this on openSUSE Leap 15

ansible -o localhost -m setup -a filter=ansible_distribution_major_version
localhost | SUCCESS => {"ansible_facts": {"ansible_distribution_major_version": "NA"}, "changed": false}

After this patch we get this

ansible -o localhost -m setup -a filter=ansible_distribution_major_version
localhost | SUCCESS => {"ansible_facts": {"ansible_distribution_major_version": "15"}, "changed": false}

This also fixes the Tumbleweed distribution test to report a proper
major version and also adds a test for openSUSE Leap 15.0 to avoid
potential future regressions.

Fixes: #41410
(cherry picked from commit 1737b7be3e)
6 years ago
Deepak Agrawal ccf2d9c8cc conflict res after patching 6 years ago
Matt Davis f9f368f123 skip winrm unit tests if winrm is not installed (#41596)
(cherry picked from commit b01779ad18)
6 years ago
Trishna Guha 09aae2e33d don't retrieve config in running_config when config is provided for diff (#41400)
* don't retrieve config in running_config when config is provided for diff

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

* fix for eos, nxos

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

* add integration test

Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
(cherry picked from commit 8ab0d654f3)
6 years ago
Toshio Kuratomi 70f4f89178 Bkprt no log fix (#41452)
* no_log even when task_result doesn't provide key

 - now also checks task property
 - added reproducer to tests for unreachable status on item loop

(cherry picked from commit 336b3762b2)

* Add changelog entry for the no_log fix

(cherry picked from commit 5fdd101a3e)

* Tasks that are expected to fail need to begin with a special string

(cherry picked from commit a5fd86cf6d)
6 years ago
Deepak Agrawal 6cdc3ac057 iosxr_config crash if config has route-policy with multiple levels of… (#41490)
* iosxr_config crash if config has route-policy with multiple levels of 'ifelseif' and other caveats (#41091)

* diff in as-path-set or prefix-set

* fix caveat diff can not have last line with comma in prefix-set/as-path/community-set

* Simplify fix to include indentation before parse

* remove debugger

* route-policy diffs

* fix iosxr_config crash issue

* new changes in iosxr_config after git add

* end-policy-map and end-class-map are properly indented so match misplaced children only when end-* is at the beigining also fix pep8

* Remaining config blocks of route-policy which needs exclusion from diff. added new tests

* pylint/pep8 warnings

* Review comments , sanity test fix

* shbang warning

* remove unused import

(cherry picked from commit 2db6a8c26a)

* changelog entry

* sanity fix
6 years ago
Matt Clay 2ef929029d Disable failing acme_account integration test.
(cherry picked from commit d6ba139713)
6 years ago
Will Thames 6c505e9ef1 cherry-picked from 46886f8249 and fixed merge conflicts
Test case for missing permissions

Update aws_s3 module to latest standards

Use AnsibleAWSModule

Handle BotoCoreErrors properly

Check for XNotImplemented and NotImplemented exceptions for S3 drop-ins

Don't prematurely fail if user does not have s3:ListBucket permission

Allow S3 drop-ins to ignore put_object_acl and put_bucket_acl
6 years ago
Yuwei Zhou ca992f5aba Fixes #39648 azure_rm_virtualnetwork not handling DNS settings properly on existing virtual networks (#40646)
* check nullable

* add test

* fix

* fix

(cherry picked from commit 7b9864776a)
6 years ago
Trishna Guha 3ed8300dff increase timeout for connection reset by peer issue with httpapi (#41224)
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
(cherry picked from commit 34e4071eca)
6 years ago
Kevin Breit c87e26449a Backport/2.6/40856 (#41278)
* Changed request() to run json.loads() instead of module doing it
- Removed json.loads() from modules
- Removed some unreliable integration tests
- Removed self.function setting in construct_path()
-

(cherry picked from commit 0ba1e52bdd)

* PEP8 changes

(cherry picked from commit 182979ffc4)

* Remove debug line for push

(cherry picked from commit 5350dcf52c)
6 years ago
Sloane Hertel c168cd482c cherry-picked from 89cea78e30 and fixed merge conflicts from restructuring the integration tests in devel
Fix async for aws_s3

Add a test that async is able to be used on aws_s3 tasks
6 years ago
Matt Martz 094c9e7a3d Revert #39365, improve error messaging (#41208)
* Revert " Update TaskInclude _raw_params with the expanded/templated path to file (#39365)"

This reverts commit 4b01b92cfe.

* Improve error messaging, catch error templating parent path

(cherry picked from commit c403f01971)
6 years ago
Jordan Borean 5417a373bc winrm: fix up unit tests (#41112)
(cherry picked from commit ad8e13e9f8)
6 years ago
Matt Clay ddb60ce345 Implement new changelog generator.
(cherry picked from commit 70c475da6c)
6 years ago
Matt Davis 14acce0b44 pin azure deps to exact versions
* added warnings for newer-than-expected versions
* prevent passing both api_version and profile for newer clients
6 years ago
saichint 9823432ec3 fix nxos_snapshot issues (#41034)
* fix nxos_snapshot issues

* review comments

* doc change

(cherry picked from commit 6733bffd5d)
6 years ago
Nathaniel Case e24743ff19 Fixes to ios_logging (#41029)
* Logging size may not show up in config

* This is much simpler

* Avoid repetition in tests

* Both options of buffered are optional

(cherry picked from commit 92a95368fe)
6 years ago
Zhikang Zhang e8d8fa4e1a Fix test-module failing to validate args (#41004)
* Fix test-module failing to validate args

The test-module pass a wrong argument _ansible_tmp cause the validation failed.
Change the argument _ansible_tmp to _ansible_tmpdir to fix this.

* Add a integration test for test-module.

Prior to this change, we don't have a test for test-module.

This change ensure the correctness of test-module script.
6 years ago
Fabian von Feilitzsch 65d96bf354 K8s dynamic collected changes (#40745)
* Move k8s modules to dynamic backend

* update required openshift version

* update -> patch

* use new dynamic client exceptions

* style

* guard urllib3 import

* guard ansibleerror import

* give more information about error cause

* format in variable

* style

* rename tests

* Search for provided kind in a few more places to match old behavior, properly handle failure

* make common code use fail instead of fail_json, to work for lookup plugins as well

* update docs

* move openshift_raw tests into k8s tests

* fix typo

* Use diff of response and resource to determine change, don't do any checking client-side before making requests

* remove duplicate yaml blocks

* Update porting guide for k8s module

* remove invalid doc refs

* If fuzzy searching finds a resource, update resource_definition to match proper kind and version

* remote unsupported openshift_raw variables

* properly check environment variables when determining auth method:
6 years ago
Nathaniel Case cad351328d Search for macaddresses more stringently (#40901)
* Search for macaddresses more stringently

Fixes #40829

(cherry picked from commit e7afd3d378)
6 years ago
Sumit Jaiswal 42661ba459 Fix for updating the name in case of host record and network view and also display meaningful error in case of connection timeout (#40597)
* To fix following github issues 35774, 36574 and 39494

* To fix following github issues 35774, 36574 and 39494

* To fix following github issues 35774, 36574 and 39494

* To fix following github issues 35774, 36574 and 39494

* To fix following github issues 35774, 36574 and 39494

* To fix following github issues 35774, 36574 and 39494

* removed old_name new entry to make ui cleaner

* removed old_name new entry to make ui cleaner

* removed old_name new entry to make ui cleaner

* removed old_name new entry to make ui cleaner

* removed old_name new entry to make ui cleaner

* removed old_name new entry to make ui cleaner

* to resolve the bug 40709

* reslove shippable error

* reslove shippable error

* reslove shippable error

* reslove shippable error

* reslove shippable error

* reslove shippable error

* reslove shippable error

* reslove shippable error

* reslove shippable error

* to fix shippable nios automation error

* modified the name input parsing method

* modified the name input parsing method

* modified the name input parsing method

* modified the name input parsing method

* modified the name input parsing method

* modified the name input parsing method

* modified the name input parsing method

* modified the name input parsing method

* modified the name input parsing method

* shippable error fix

* shippable error fix

* shippable error fix

* shippable error fix

* shippable error fix

* review comment fix

* shippable error fix

* shippable error fix

(cherry picked from commit 81510970ae)
6 years ago
Nilashish Chakraborty 1ea5790f56 Fixes eos_logging idempotence issue #31862 (#40604)
* eos_logging idempotence fix

* fixed eos_logging idempotence issue

* Fixed pylint and pep8 errors

* Added tests for eos_logging & minor fix

* Removed q statements

(cherry picked from commit b9ea646839)
6 years ago
Nilashish Chakraborty a3178a1153 Fixes ios_logging idempotency issues (#40701)
* Fixes ios_logging idempotency issues

* Added intergration tests & minor fixes

* Minor fixes in tests

* Minor fixes in tests #2

* eos_logging fixes after PR review

(cherry picked from commit a013cdc747)
6 years ago
Matt Martz 87a163064f
Backport #40833 for 2.6 - synchronize _remote_is_local (#40918)
* Use _remote_is_local=True for local connection in synchronize (#40833)

* All instances of local connection should use _remote_is_local=True. Fixes #40551

* Switch to instance attribute for synchronize

* Add test that shows that synchronize _remote_is_local addresses tmpdir building

(cherry picked from commit ad7ba91f75)

* Add changelog entry for #40833
6 years ago
Matt Clay b184e73b89 Fix FreeBSD package install in test setup.sh.
(cherry picked from commit c3d3b6cedc)
6 years ago
Nathaniel Case 848327a6b5
Fix eapi tests to use become (#40838) (#40848)
* Fix eapi tests to use become (#40838)

* Return the expected prompt character based on become status

* Update eos_banner tests for eapi

* Update eos_config tests for eapi

* Update eos_facts tests for eapi

* Update eos_interface tests for eapi

* Update eos_l3_interface tests for eapi

* Update eos_lldp tests for eapi

* Update eos_logging tests for eapi

* Update eos_smoke tests for eapi

* Update eos_system tests for eapi

(cherry picked from commit 20f93816d6)

* Remove local from most eos tests now that provider is out
6 years ago