Commit graph

7847 commits

Author SHA1 Message Date
Matt Davis
837ea4b39f tag off long-running azure_rm_virtualnetworkgateway tests 2019-04-12 14:03:35 -07:00
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
2019-04-12 12:57:35 -07:00
Toshio Kuratomi
e5a31e81b6 Add a script to generate a new porting guide
* porting-guide.py is allowed to be Python-3.6+ as it will only be run
  by release engineers
2019-04-12 12:57:35 -07:00
Matt Clay
a4d0c24bbf
Fix ansible-test inventory and vars path handling. (#55186)
* Fix ansible-test inventory and vars path handling.
* Improve explanation for missing commit.
2019-04-12 11:52:44 -07:00
Brian Coca
9f87552f06
add option to display per host start to default (#53819)
* add option to display per host start to default
2019-04-12 12:42:38 -04:00
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`
2019-04-12 09:18:06 -07:00
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
2019-04-12 12:13:55 -04:00
Bob Boldin
9ddde6b27f AWS: add ec2_transit_gateway_info module (#54460)
* AWS: add ec2_transit_gateway_info module

* move info module test to main module and ensure unique description for parallel tests

* add type designators to module options in documentation

* assign results and return instead of exit.  Add elements directive available with ansible 2.8

* assign results and return instead of exit

* get() method superfluous for module.params

* correct return type in documentation for ASN and format the sample for Tag correctly

* added random uid to test description - removing unstable alias

* change random uuid to resource_prefix to improve source of object identification in testing
2019-04-13 01:35:39 +10:00
Andrey Klychkov
d790285e80 postgresql_idx: improved doc, tests, remove useless lines from code (#55131)
* postgresql_idx: improve doc

* postgresql_idx: improve doc, removed unuseless rows from code

* postgresql_idx: misc doc fix

* postgresql_idx: moved common params where they were

* postgresql_idx: moved common params where they were 2
2019-04-12 14:15:21 +01:00
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>
2019-04-11 20:59:11 +05:30
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.
2019-04-11 11:16:45 -04:00
Hannes Ljungberg
23d0d225f4 docker_swarm_service_info: Read information about swarm services (#55008)
* Add docker_swarm_service_info module

* Remove unused import

* Limit to retrieving info about one service

* Add exists return value

* Add yaml 3-dash

Co-Authored-By: hannseman <hannes@5monkeys.se>

* Document return value as jinja `none´

Co-Authored-By: hannseman <hannes@5monkeys.se>

* Name is required
2019-04-11 12:30:00 +02:00
Zim Kalinowski
5145473451
adding facts for Azure HDINsight cluster (#55124) 2019-04-11 15:08:01 +08:00
Matt Davis
1dc8436ed9
module_utils fixes in collections (#55118)
* module_utils fixes in collections

* fixed Windows module_utils in collections
* fixed more Python module_utils cases (from X import module)
* "medium style" Ansiballz modules now work properly with collections (ie, non-replacer but also not using basic.py)
* added more tests
* split Windows/POSIX exec

* sanity
2019-04-10 22:59:53 -07:00
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>
2019-04-11 11:02:08 +05:30
Yunge Zhu
ed1334fbe3
add wait_for_running option in azure_rm_rediscache module (#54976) 2019-04-11 11:17:31 +08:00
Chris Archibald
e12846f540 Update na_ontap_export_policy_rule to allow multiple rules to be set at once. (#54801)
* update

* add unit tests
2019-04-10 20:48:49 -04:00
Madhura-CSI
fe31b7eddb New module for azure virtual network gateway (#44411)
* module for azure vpn gateway

* updating vng
2019-04-10 17:47:33 -07:00
Sam Doran
c2be342ce1 Add podman_image and podman_image_info modules (#55103)
* Add podman_image and podman_image_info modules

* Add integration test for podman_image_info

* Change parameter names per feedback

* Add integration tests for podman_image
2019-04-10 18:28:09 -05:00
René Moser
e28d08a3c1
cloudscale_server: implement param server_groups (#54868) 2019-04-11 00:16:35 +02:00
Chris Archibald
c51f840faa Allow for multiple LIFS instead of 1 at a time (#54800)
* upload unit tests
2019-04-11 00:15:08 +02:00
Felix Fontein
7d2e4dd2fd ufw: fix default (again) (#55004) 2019-04-11 00:06:53 +02:00
Ondra Machacek
af528bed80 inventory_plugins: Add kubevirt inventory plugin
Signed-off-by: Ondra Machacek <omachace@redhat.com>
2019-04-10 17:34:13 -04:00
Gaudenz Steinlin
a290cb4a35 Add cloudscale.ch API inventory plugin (#53517) 2019-04-10 20:01:13 +02:00
René Moser
166a33ef4d
cloudscale: new module cloudscale_server_group (#54901) 2019-04-10 18:50:59 +02:00
Matt Martz
e89f8bae86
Extend jinja2 nested undefined support to keys/indices (#55094) 2019-04-10 10:35:31 -05:00
咚咔
72fc11ff13 Fix read vaulted toml inventory (#54226) (#54235) 2019-04-10 09:10:48 -05:00
Karolis Tamutis
54384e7a12 Make test-module use default value for interpreter (#54053)
* Make test-module use default value for interpreter

* Changing from static interpreter path to sys.executable as per #54053

* A little ntegration test for #54053
2019-04-10 09:04:49 -05:00
Lukas Kämmerling
3f579eb68f hcloud: Fix testsuite (#55076) 2019-04-10 15:16:10 +02:00
Andrey Klychkov
a971a0eb80 New module postgresql_slot: Add or remove slots from a PostgreSQL database (#55079)
* New module postgresql_slot

* New module postgresql_slot: fixed sanity

* New module postgresql_slot: fixes

* New module postgresql_slot: fixes

* New module postgresql_slot: fix sanity
2019-04-10 14:12:57 +01:00
Andrea Tartaglia
0303ea2bfa openssl_pkcs12: Add idempotency checks (#54633)
* Added idempotency logic to openssl_pkcs12

Also decoupled the 'parse' and 'generate' function from the file write
as they are now used in different places that do not need the file to be
written to disk.

* Added idempotency tests for openssl_pkcs12

Also adds a new test for pkcs12 files with multiple certificates

* Regenerate if parsed file is invalid

* pkcs12_other_certificates check was wrong

* Updated ca_certificates to other_certificates

ca_certificates is left as an alias to other_certificates;
friendlyname depends on private key, so it will be ignored while
checking for idempotency if the pkey is not set;
idempotency check only checks for correct certs in the stack

* use different keys for different certs

* Added other_certificates in module docs

* Added changelog and porting guide

* removed unrelated porting guide entry

* renamed ca_cert* occurrence with other_cert
2019-04-10 11:43:08 +01:00
Matt Clay
5b133f3455 Compat fix for ansible-core-ci on Python 3.7. 2019-04-10 00:37:05 -07:00
Dag Wieers
025e9afe58 Windows pslint: Re-enable PSPossibleIncorrectComparisonWithNull (#55065)
* pslint fixes

* Fix up remaining sanity issues

* now fix silly errors I made
2019-04-10 15:30:38 +10:00
Jordan Borean
58e076b64c
Increase async timeout for psrp connection test (#55068) 2019-04-10 13:56:27 +10:00
Dag Wieers
e6935a285b Allow pslint as user (#55066) 2019-04-10 13:06:22 +10:00
Abhijeet Kasurde
98692ab350
VMware: Add check for valid VLAN id range (#55023)
Check allows vmware_dvs_portgroup to fail early if user
specified invalid range in VLAN id(s).

Fixes: #54927

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2019-04-10 08:09:21 +05:30
Abhijeet Kasurde
a62adaefa9
test: regex_ testcases (#54972)
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2019-04-10 08:04:55 +05:30
Matt Clay
3d9a9ec73f
Mark hcloud_ssh_key test disabled. (#55064) 2019-04-09 16:53:35 -07:00
Micah Hunsberger
2b049238d6 win_firewall_rule only change arguments passed by user (#54297)
* win_firewall_rule only changes specified arguments
defaults are controlled by com object
integration test for built in rule

* removed ignore psaliases for win_firewall_rule

* direction and action are no longer required
program and service respect default values
documentation updated to reflect that defaults apply to rule creation
added test to disable a rule and verify other values have not changed

* fixed extra whitespace

* Move each description sentance to a new entry
2019-04-10 09:27:31 +10:00
Matt Clay
365db9057c Mark hcloud_server_facts tests unstable. 2019-04-09 15:58:25 -07:00
Matt Clay
85ae8f5258 Add Hetzner Cloud to CI integration tests. 2019-04-09 15:41:50 -07:00
Rémy Léone
16c4df439a Migrate Scaleway tests to integration tests 2019-04-09 15:41:30 -07:00
Jordan Borean
ebd4462c23
Fix tests for the psrp connection plugin (#55061) 2019-04-10 08:22:48 +10:00
Matt Davis
97446f0eca
Revert "Add a force_replace_host flag to win_domain_membership (#53542)" (#55056)
This reverts commit 85d836171b.

As discussed in WWG IRC meeting, we don't want Get-ADObject to be a dependency of win_domain_membership, and we need to be able to authenticate to the DC in some configs. We can revisit this change a different way for 2.9.
2019-04-09 13:52:23 -07:00
Felix Fontein
df72317b29 Don't complain if type() is used. (#54849) 2019-04-09 15:10:32 -05:00
Matt Clay
5285044a7a Update Paramiko install during tests on RHEL 8. 2019-04-09 11:04:30 -07:00
Sam Doran
3cd98a9fcc Use ansible.module_utils.six in inventory scripts (#55000)
* Use six from ansible.module_utils for inventory scripts

Remove skips from sanity test

* Change all imports of ConfigParser to use module_utils.six.moves

* Remove commented out lines

* Fix six imports
2019-04-09 13:17:59 -04:00
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
2019-04-09 10:14:42 -05:00
Hideki Saito
377fba3d76 Fix handling of inventory and credential options for tower_job_launch (#54967)
- Fixed issue #25017,#37567
- Add example for prompt on launch
- Add integration test for prompt on launch

Signed-off-by: Hideki Saito <saito@fgrep.org>
2019-04-09 14:08:11 +01:00
Andrey Klychkov
5cbac14469 New module postgresql_owner: change ownership and reassign all db objects owned by role to another (#54984) 2019-04-09 13:32:09 +01:00
Raymond Roelands
8edae1bc61 updated tests and changelog for 54516 (#54670)
* updated tests and changelog for 54516

* Handle errors if PG does not support partitioning.

* Check for PG > 10 in tasks

* Show changes for partitioned tables in ansible

* Added documentation in the tests

* Update test/integration/targets/postgresql/tasks/postgresql_privs.yml

Co-Authored-By: raymondroelands <raymondroelands@users.noreply.github.com>

* Update test/integration/targets/postgresql/tasks/postgresql_privs.yml

Co-Authored-By: raymondroelands <raymondroelands@users.noreply.github.com>

* Added check for 0 tables after revoking rights

* Added test and moved tests
Added check mode test and moved test right after the change.

* Rebased postgresql_privs.py
2019-04-09 13:30:06 +02:00
Felix Fontein
bb52390b04 luks_device: add basic check mode (#54477)
* Add basic check mode.

* One more early exit.

* Fix naming.

* Check that device is actually an existing device.
2019-04-09 11:32:22 +02:00
Yunge Zhu
cb2972d647
refine role modules (#55021) 2019-04-09 16:05:03 +08:00
Felix Fontein
0a0a2e47e0 Add openssl_csr_info module (#54921)
* Add openssl_csr_info module.

* Make OpenSSL < 1.1 compatible.

* Simply remove signature algorithm.

* Adjust minimal version.

* Fallback code for some pyOpenSSL < 16.0 versions.
2019-04-09 12:48:22 +05:30
Matt Clay
d5707088b9 Mark ufw integration test unstable.
The test fails when run in the group, but not by itself.
2019-04-08 16:34:55 -07:00
Varun Chopra
4651bcf561 Add win_format (#53925)
* Add win_format

* Some doc changes were missed

* Fixes for ansible-test, additional assertion for check mode

* Fix -WhatIf issues

* Support for idempotency and changes to integration tests

* Fix trailing whitespace

* Fixes from review, and added check for non-empty volumes

* Remove an extra line

* Structural changes

* Minor fixes for CI
2019-04-09 06:45:04 +10:00
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()
2019-04-08 16:26:31 -04:00
Matt Clay
58f4947ffe Fix apache shutdown in subversion test. 2019-04-08 10:33:35 -07:00
Felix Fontein
7d27348356 ufw: fix default, direction is not necessary for it (#54799)
* Correct behavior so that direction isn't required for default.
* Add more tests.
* 'disabled' values cannot be changed.
* Include 'not specified' in messages.
2019-04-08 08:49:35 -04:00
Chris Archibald
c6f12eea32 push fix (#54916) 2019-04-08 13:11:42 +01:00
Robert Osowiecki
1532e31ec0 Allow all of yum version compare operators (#54603)
* Allow all of yum version compare operators

* * yum: name="foo >= VERSION" integration test
* changelog fragment
2019-04-08 10:34:21 +02:00
Felix Fontein
221da3e8b1 Implement Ed25519, Ed448, X25519 and X448 support (cryptography backend). (#54947) 2019-04-08 10:30:05 +02:00
Felix Fontein
7a16703dff Add openssl_privatekey_info module (#54845)
* Add openssl_privatekey_info module.

* Addressing review feedback.

* Update docs.

* Update tests.

* Work around too broad sanity checks.

* ...

* Don't die when None is returned.

* Use OpenSSL to extract RSA and DSA key data.

* Extend tests.

* Make OpenSSL code compatible to OpenSSL < 1.1.

* Rewrite tests to use result dicts instead of result lists.

* Skip ECC for too old PyOpenSSL.

* Reformulate.

* Improve return_private_key_data docs.

* Rename path_content -> content.

* Add sample.

* Cleanup.

* Add key consistency check.

* Improve description.

* Adjust minimal version.

* Fallback code for some pyOpenSSL < 16.0 versions.

* Also support Ed25519 and Ed448 keys (or not).

* Add more consistency checks.

* Verify DSA keys manually.

* Improve DSA key validation.

* Forgot one condition.

* Make validation more robust.

* Move generic arithmetic code to module_utils/crypto.py.
2019-04-08 10:07:56 +02:00
Anil Kumar Muraleedharan
f5d97205a0 The module fails on switchport. Check added to fix. (#54970) 2019-04-08 10:41:36 +05:30
Zim Kalinowski
ea609c3492
adding plan and container settings to function app (#54830) 2019-04-08 11:05:21 +08:00
Felix Fontein
b92281fe70 Simplify test include. (#54962) 2019-04-07 16:51:14 -04:00
William Leemans
993727ff5e New module: xfs_quota (#51654)
* New module: xfs_quota

* wildcard import resolution

* pep8 fixes

* validate-modules fixes

* pep8 and validate-module fixes

* removal of extra copyright info

* description capitalization and trailing dot

* Some more description

* type specification

* removal of notes

* reorder imports

* sorting

* starting with variable type

* removal of defaults

* results to dict

* results to dict

* complete condition

* removal of spaces for pep8 compliancy, removal of root check, addition of tests for failed xfs_quota commands indicating the need for elevation/capabilities

* lost result

* typo

* historical override removal

* report back values

* unexpected spaces removal

* Update lib/ansible/modules/system/xfs_quota.py

Co-Authored-By: bushvin <bushvin@users.noreply.github.com>

* Update lib/ansible/modules/system/xfs_quota.py

Co-Authored-By: bushvin <bushvin@users.noreply.github.com>

* Update lib/ansible/modules/system/xfs_quota.py

Co-Authored-By: bushvin <bushvin@users.noreply.github.com>

* Update lib/ansible/modules/system/xfs_quota.py

Co-Authored-By: bushvin <bushvin@users.noreply.github.com>

* Update lib/ansible/modules/system/xfs_quota.py

Co-Authored-By: bushvin <bushvin@users.noreply.github.com>

* Update lib/ansible/modules/system/xfs_quota.py

Co-Authored-By: bushvin <bushvin@users.noreply.github.com>

* Update lib/ansible/modules/system/xfs_quota.py

Co-Authored-By: bushvin <bushvin@users.noreply.github.com>

* Update lib/ansible/modules/system/xfs_quota.py

Co-Authored-By: bushvin <bushvin@users.noreply.github.com>

* Update lib/ansible/modules/system/xfs_quota.py

Co-Authored-By: bushvin <bushvin@users.noreply.github.com>

* Update lib/ansible/modules/system/xfs_quota.py

Co-Authored-By: bushvin <bushvin@users.noreply.github.com>

* Update lib/ansible/modules/system/xfs_quota.py

Co-Authored-By: bushvin <bushvin@users.noreply.github.com>

* Update lib/ansible/modules/system/xfs_quota.py

Co-Authored-By: bushvin <bushvin@users.noreply.github.com>

* Update lib/ansible/modules/system/xfs_quota.py

Co-Authored-By: bushvin <bushvin@users.noreply.github.com>

* Update lib/ansible/modules/system/xfs_quota.py

Co-Authored-By: bushvin <bushvin@users.noreply.github.com>

* Update lib/ansible/modules/system/xfs_quota.py

Co-Authored-By: bushvin <bushvin@users.noreply.github.com>

* Update lib/ansible/modules/system/xfs_quota.py

Co-Authored-By: bushvin <bushvin@users.noreply.github.com>

* Update lib/ansible/modules/system/xfs_quota.py

Co-Authored-By: bushvin <bushvin@users.noreply.github.com>

* typo

* raw data, full data

* removal of several else: statements and indentation

* pep8

* typo

* Update lib/ansible/modules/system/xfs_quota.py

Co-Authored-By: bushvin <bushvin@users.noreply.github.com>

* Update lib/ansible/modules/system/xfs_quota.py

Co-Authored-By: bushvin <bushvin@users.noreply.github.com>

* Update lib/ansible/modules/system/xfs_quota.py

Co-Authored-By: bushvin <bushvin@users.noreply.github.com>

* Update lib/ansible/modules/system/xfs_quota.py

Co-Authored-By: bushvin <bushvin@users.noreply.github.com>

* Update lib/ansible/modules/system/xfs_quota.py

Co-Authored-By: bushvin <bushvin@users.noreply.github.com>

* Update lib/ansible/modules/system/xfs_quota.py

Co-Authored-By: bushvin <bushvin@users.noreply.github.com>

* Update lib/ansible/modules/system/xfs_quota.py

Co-Authored-By: bushvin <bushvin@users.noreply.github.com>

* typo

* use bytes as base, not kilobytes

* be consistent

* integration tests

* lint

* empty lines

* Update lib/ansible/modules/system/xfs_quota.py

Co-Authored-By: bushvin <bushvin@users.noreply.github.com>

* updates

* ci group

* XFS not supported on osx

* XFS not supported by freebsd

* long lines and removal of xfs_quota dict in return

* RETURN values

* no more xfs_quota dict
2019-04-07 20:11:32 +01:00
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
2019-04-07 15:47:11 +05:30
Matt Clay
a4c42ba687
Update the default test container to 1.7.0. (#54930)
* Update the default test container to 1.7.0.
* Run `pip check` after installing test requirements.
* Support older versions of pip.
* Remove obsolete pip error handler.
2019-04-05 22:34:38 -07:00
Anil Kumar Muraleedharan
c2958df3a4 Removing provider from facts, command and config (#54623) 2019-04-05 21:50:29 -04:00
Matt Clay
4b3662605d Limit supervisor in tests to < 4.0.0.
Tests fail when using version 4.0.0.
2019-04-05 17:48:31 -07:00
Matt Clay
ab7f810874
Only use Paramiko in tests when needed. (#54826) 2019-04-05 17:31:33 -07:00
Matt Clay
c309570540 Start dbus when setting up postgresql tests. 2019-04-05 16:55:43 -07:00
Matt Davis
2b9b5f5bb7
fix rediscache/firewall tests (#54933)
* cleaned up tagging to prevent long-running tasks in CI
2019-04-05 16:30:57 -07:00
Lukas Kämmerling
22e1f33f5e Add rebuild server functionality (#54899) 2019-04-05 21:31:31 +02:00
Matt Clay
dd09a9a9fd Install EPEL on RHEL using RPM from S3. 2019-04-05 11:40:13 -07:00
Matt Clay
c846501829 Increase unit test timeout for --coverage. 2019-04-05 09:43:42 -07:00
Felix Fontein
65d7f0d17b Add openssl_certificate_info module (#54709)
* Add certificate_info module.

* Improve normalization.

* Add extension dump.

* Add support for basic_constraints and ocsp_must_staple.

* Update docs.

* Add serial number.

* Remove superfluous code.

* Fix formulation.

* Improve examples.

* Improve result docs.

* Forgot to add tests.

* Adjust when no fingerprints can be computed.
2019-04-05 15:47:05 +01:00
Jordan Borean
10a9cf59dd
Added win_http_proxy and win_inet_proxy (#54631)
* Added win_http_proxy and win_inet_proxy

* Fix up docs sanity issues

* removed duplicate doc entry

* Fix docs issues and fix for empty proxy

* Removed <-loopback> for win_http_proxy

* doc changes from review
2019-04-05 11:19:30 +10:00
Felix Fontein
14b3b3a95e openssl_certificate now has cryptography backend (#53924). (#54880) 2019-04-04 17:19:58 -04:00
Felix Fontein
8cba1f9397 docker_network: add IPAM driver options support (#54632)
* Tidying up.

* Adding ipam_driver_options parameter.

* Add tests.

* Add changelog.
2019-04-04 15:44:31 -04:00
Matt Clay
f0480ab132
Fix timezone test for newer Fedora containers. (#54874) 2019-04-04 11:11:31 -07:00
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
2019-04-04 09:59:52 -04:00
Andrey Klychkov
2fbac8948d postgresql_idx: added CI tests for check_mode, rewrite code related with check_mode, misc fixes (#54848)
* postgresql_idx: added CI tests, misc fixes

* postgresql_idx: fix sanity
2019-04-04 13:31:14 +01:00
Andrey Klychkov
3eff72e886 postgresql_user: fix doc formatting, added return value, aliases, misc code changes (#54768)
* postgresql_user: refactoring

* postgresql_user: removed line from ignore.txt

* postgresql_user: removed lines from ignore.txt

* postgresql_user: removed lines from ignore.txt, fixes

* postgresql_user: removed lines from ignore.txt, fixes

* postgresql_user: removed lines from ignore.txt, fixes
2019-04-04 10:02:23 +01:00
zhongjun2
d16452bc8f Added smn module (#54793) 2019-04-04 08:55:34 +01:00
Matt Clay
51829303d2 Rebalance Azure tests. 2019-04-03 23:59:04 -07:00
Matt Clay
414ac12ddd Add work-around for scp issue in tests. 2019-04-03 23:39:45 -07:00
Zim Kalinowski
69ca89858c
Renaming azure_rm_managed_disk for consistency (#54825) 2019-04-04 12:24:03 +08:00
Sam Doran
6ce9cf7741
Change default smart connection to ssh on macOS and remove paramiko from requirements.txt (#54738)
* Remove default use of paramiko connection plugin on macOS
    This fix was originally to work around a bug that caused a kernel panic on macOS
    that has since been fixed.
* Remove paramiko from requirements.txt
* Move paramiko checking to common place
* Drop the warnings obfiscation code
* Update pip installation instructions to reflect upstream instructions
* Fix tests on CentOS 6 (Python 2.6) that now show Python deprecation warnings
* Add changelog fragment
2019-04-03 22:35:59 -04:00
Matt Clay
9776037abe Disable failing azure_rm_webapp test. 2019-04-03 17:48:27 -07:00
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
2019-04-03 20:56:35 +01:00
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
2019-04-03 23:22:45 +05:30
Martin Krizek
d15812fabf
Fix copy module to reset filesystem acls (#51868)
The controller's fixup_perms2 uses filesystem acls to make the temporary
file for copy readable by an unprivileged become user. On Python3, the
acls are then copied to the destination filename so we have to remove
them from there.

We can't remove them prior to the copy because we may not have
permission to read the file if the acls are not present. We can't
remove them in atomic_move() because the move function shouldn't know
anything about controller features. We may want to generalize this into
a helper function, though.

Fixes #44412

Co-authored-by: Toshio Kuratomi <a.badger@gmail.com>
2019-04-03 18:37:59 +02:00
Zim Kalinowski
4f0ad57934 renaming info -> facts (#54573) 2019-04-03 23:03:47 +08:00
Yunge Zhu
a387b8e239
add vnet peering facts module (#53942) 2019-04-03 22:22:16 +08:00
Matt Clay
9e30300034 Add 6th Windows CI group. 2019-04-02 23:41:43 -07:00
Zim Kalinowski
73286ceca5 fixing azure_rm_devtestlab* test (#54716) 2019-04-03 14:03:19 +08:00
Zim Kalinowski
138fc11ee0 fixing role definition test (#54715) 2019-04-03 14:02:19 +08:00
Fred-sun
3694711a7e Update azure_rm_managed_disk.py --add zones (#53788) 2019-04-03 11:08:27 +08:00
Matt Clay
c8f2becb7a Reduce testing of Ubuntu versions.
Removing:

- Ubuntu 14.04 with Python 2.7
- Ubuntu 16.04 with Python 3.5

Keeping:

- Ubuntu 16.04 with Python 2.7
- Ubuntu 18.04 with Python 3.6
2019-04-02 17:30:34 -07:00
Steve Bonds
524160d8d1 Fetching a test file, not the motd file (#54739) 2019-04-02 15:58:54 -05:00
Jordan Borean
b13fa0d408
Ansible.Basic - event log perm fix and no_log improv (#54699)
* Ansible.Basic - event log perm fix and no_log improv

* Still log other failures
2019-04-03 06:49:43 +10:00
Jordan Borean
8b1b22ddc7
Bump dependency versions to avoid conflicts (#54443)
* Bump dependency versions to avoid conflicts

* Fix module code to support newer SDK packages

* Fix keyvault module are upgrading deps
2019-04-03 05:40:52 +10:00
Andrey Klychkov
40f65a54ec Postgresql privs reformat (#54717)
* postgresql_privs: fix doc format, pgutils

* postgresql_privs: added pgutils, ret value

* postgresql_privs: fix test

* postgresql_privs: fixes

* postgresql_privs: fixes

* postgresql_privs: fixed CI
2019-04-02 16:48:35 +01:00
Sam Doran
579e72573a Add BusyBox support to group module (#54689)
* Add BusyBox support to group module

* Use bytes when reading/writing to file
2019-04-02 09:58:04 -04:00
Matt Clay
d01c1599b0 Remove redundant requirements from test. 2019-04-01 18:23:44 -07:00
Jordan Borean
c40f41d519
win_credential - fix encoding for text based secrets (#54695)
* win_credential - fix encoding for text based secrets

* Fix py2 encoding issues
2019-04-02 09:29:05 +10:00
Christopher Schmitt
cafd124288 Add ssh key facts for hcloud (#54518)
* Add ssh_key facts

* Fix documentation
2019-04-01 19:07:59 +01:00
Lukas Kämmerling
72f1e4b83a Add hcloud_volume_facts (#54666)
* Add hcloud_volume_facts

* Fix server name
2019-04-01 17:25:46 +01:00
Chris Archibald
ec03ddd336 Multiple fixs for na_ontap_user (#54610)
* Fix ontap user for 9.1

* fix bugs:

* update unit tests
2019-04-01 17:22:48 +01:00
Łukasz Szczęsny
bcdd1dc951 pamd: fix idempotence issue when removing rules (#54105) 2019-04-01 10:18:33 -04:00
Andrey Klychkov
48ec8d13a0 postgresql_lang module: fixed doc formatting, added aliases, pg_utils, added missing CI tests (#54672)
* postgresql_lang: fixed doc

* postgresql_lang: add pg_utils

* postgresql_lang: added return value - queries

* postgresql_lang: added CI tests

* postgresql_lang: restricted CI using CentOS

* postgresql_lang: fixed typos in CI comments
2019-04-01 14:39:00 +01:00
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
2019-04-01 18:08:01 +05:30
Hannes Ljungberg
e58f23b73e docker_swarm: Return UnlockKey (#54490)
* Return UnlockKey

* Add changelog fragment

* Add method to check if a parameter exists in diffs

* Add method to get swarm unlock key

* Add option unlock_key

* Only return unlock key when created or changed

* Rename difference check

* Extend unlock key example

* Assert that unlock_key is a string

* Fix docker_swarm_info authors

* Don’t silence APIErrors

* Test unlock_key on unlocked swarm

* Catch APIError when retrieving unlock key

* Better return value description

* Lint

* Fix UnlockKey return value documentation

Co-Authored-By: hannseman <hannes@5monkeys.se>

* Get unlock key safely

Co-Authored-By: hannseman <hannes@5monkeys.se>

* Return None on empty UnlockKey

* Assert swarm_unlock_key is undefined if unqueried

* Add documentation about swarm_info unlock_key

* Add change log fragment for unlock_key option

* Revert "Add change log fragment for unlock_key option"

This reverts commit e3cb2325b5.

* Use generator expression instead

* Restart docker more decisively

* Use systemctl kill

Co-Authored-By: hannseman <hannes@5monkeys.se>

* Try to restart docker daemon
2019-04-01 12:19:18 +01:00
Jakob Ackermann
21c8650180 openssh_cert: add serial_number param (#54653)
* [openssh_cert] cleanup the returned certificate info

- Drop the certificate path - it is already present in rc.filename.
- Drop the leading whitespace for all lines.

Signed-off-by: Jakob Ackermann <das7pad@outlook.com>

* [openssh_cert] add support for a certificate serial number

Signed-off-by: Jakob Ackermann <das7pad@outlook.com>

* [openssh_cert] fix lint error

Signed-off-by: Jakob Ackermann <das7pad@outlook.com>

* [openssh_cert] drop explicit default value

Signed-off-by: Jakob Ackermann <das7pad@outlook.com>

* [openssh_cert] enforce the specified or missing serial number

Signed-off-by: Jakob Ackermann <das7pad@outlook.com>

* [openssh_cert] passing no explicit serial number ignores any present one

Signed-off-by: Jakob Ackermann <das7pad@outlook.com>
2019-04-01 12:18:33 +01:00
Lukas Kämmerling
f99d1b3e47 Add hcloud_floating_ip_facts module (#54667) 2019-04-01 13:16:24 +02:00
Yunge Zhu
23670913ba
support application security group in network security group (#54584) 2019-04-01 16:56:16 +08:00
Zim Kalinowski
c85e3e0794
Fix for function app settings (#54662) 2019-04-01 16:50:08 +08:00
Yunge Zhu
11e3cc3cab
add azure_rm_rediscache reboot/regenerate key (#54572) 2019-04-01 13:54:08 +08:00
Zim Kalinowski
f9877fca18
Rename inconsistent azure_rm_virtualmachine_scaleset modules (#54579)
@yungezz yes, i remember. pls keep in mind that they are not broken
2019-04-01 13:05:45 +08:00
James E. King III
97e7266633 azure_rm_managed_disk additional disk types (#54644) 2019-04-01 11:04:14 +08:00
René Moser
01f63ee871
cloudstack: fix E326 (#54657)
* cloudstack: remove choice list for hypervisor param

* cloudstack: streamline network_type with returned value by the API

* cloudstack: remove E326

* add changelog fragment
2019-03-31 23:36:56 +02:00
Hannes Ljungberg
833512b07c docker_swarm: Add support for default_addr_pool and subnet_size (#54642)
* Add support for default_addr_pool and subnet_size

* Add changelog fragment

* Document options only used on init / join
2019-03-31 16:56:55 -04:00
Micah Hunsberger
26d9341891 Add new windows module: win_hosts (#46450)
* Add win_hosts module

added win_hosts module for easier manipulation of hosts entries in "%windir%\system32\drivers\etc\hosts" for windows systems

* Update win_hosts.py

* Add alias support to win_hosts module (#1)

* win_hosts supports aliases

added support for adding / removing aliases from a host entry, rather than adding a new entry

added ability for win_hosts to detect aliases:
`192.168.1.1 alias1 alias2 alias3`
```
win_hosts:
  host_name: alias2
  ip_address: 192.168.1.1
```
will result in `192.168.1.1 alias1 alias3`

also includes `replace` and `add` as options for `ip_action` (`replace` is default)

for example:
```
192.168.1.1 my_reused_alias
192.168.1.2 my_reused_alias
```
with
```
win_hosts:
  host_name: my_reused_alias
  ip_address: 192.168.1.3
  ip_action: add
```
the result will be
```
192.168.1.1 my_reused_alias
192.168.1.2 my_reused_alias
```
but with `ip_action=replace` the result would be
```
192.168.1.3 my_reused_alias
```

* fixed metadata version and version added

* fix line endings

* upload fixed line endings

try to upload the file with the fixed line endings

* aliases and canonical names are separate entities. added IPv4 and IPv6 validation

* only makes changes if "check_mode" is false

* improved behavior for duplicate aliases/entries.

* adding tests

* missing aliases file

* fix trailing whitespace and uses explicit paths

* Tweak tests to copy and restore original hosts file
2019-04-01 06:54:05 +10:00
Kevin Subileau
09979e899f win_nssm: refactor to fix issues, support check mode and add more features (#45693)
* win_nssm: rename cmdlets to use approved verbs, rename service name parameters

* win_nssm: improve code style and cmdlets ordering

* win_nssm: always escape all command line parameters with Argv-ToString

fix error when the service name contains quotes

* win_nssm: use Fail-Json instead of exceptions and remove global try/catch

* win_nssm: small refactoring, inline some functions

* win_nssm: refactoring - add a generic cmdlet to idempotently set any nssm service parameter

* win_nssm: refactoring - inline some functions

To make the code more malleable for future changes

* win_nssm: change application, stdout_file and stderr_file options type to path

* win_nssm: deprecates app_parameters, rename app_parameters_free_form to arguments, and add support for list of parameters

* win_nssm: add support of check mode

* win_nssm: add working_directory option

* win_nssm: add display_name and description options

* win_nssm: minor changes

* win_nssm: remove some sanity exclusions

* win_nssm: avoid using aliases and minor style fixes

* win_nssm: doc and ui improvements

* win_nssm: remove sanity exclusions

* win_nssm: minor revision

* win_nssm: deprecates dependencies, start_mode, user and password parameters and some choices of state in favor of win_service

* win_nssm: fix style

* win_nssm: add executable option to specify the location of the NSSM utility

* win_nssm: add missing parameter types

* win_nssm: add diff mode support

* win_nssm: avoid displaying depreciation warning if default value is assigned

* win_nssm: fix variable scope

* win_nssm: use the explicit -LiteralPath parameter name instead of -Path

* win_nssm: fix documentation

* win_nssm: add porting guide entries

* win_nssm: add changelog fragment
2019-04-01 05:56:48 +10:00
David Passante
eff1f8851c cloudstack: streamline modules doc (part 6) (#54641)
* Parameter types added
* Copyright format fixes
* Doc style fixes
* Examples format fixes
* validate-module errors fixes
2019-03-31 11:09:15 +02:00
Wojciech Wypior
6a27e308dd BIGIP: deprecates TMOS v11.x support for GTM modules (#54543)
* deprecates TMOS v11 support for GTM modules

* correct version

* correct version
2019-03-30 14:52:55 -07:00
zhongjun2
5599b0484f cloud: huawei: Add new module hwc_network_vpc (#54102) 2019-03-30 17:20:54 +01:00
Felix Fontein
188903448a openssl_*: add backup option (#54294) 2019-03-30 15:38:43 +01:00
Felix Fontein
90c067e947 openssl_* modules: private key errors (#54088)
* Improve error handling, in particular with respect to private key loading problems.

* Add tests to validate that modules regenerate invalid input and don't crash.

* Don't crash when input is invalid.

* Create 'better' broken input.

* Fix paths.

* Simplifying pyOpenSSL error handling.
2019-03-30 14:28:10 +01:00
Matt Clay
9e1c99ed60
Enable ec2_transit_gateway test in CI. (#54619)
* Enable ec2_transit_gateway test in CI.

* Mark the test unstable.

The test sometimes attempts to delete the transit gateway while it
is in the pending state, which is not permitted.
2019-03-29 13:38:50 -07:00
Patryk D. Cichy
6b3246164c Enable adding VLAN IP ranges for Physical Networks (#54576) 2019-03-29 20:08:14 +01:00
Matt Clay
e59c1854eb Remove invalid test alias. 2019-03-29 11:37:36 -07:00
Andrey Klychkov
349a0dccee New module postgresql_table - create postgresql table on remote host (#52077)
* New module postgresql_table - create postgresql table on remote host

* New module postgresql_table - fix tests

* New module postgresql_table - fix tests

* New module postgresql_table - fix tests

* New module postgresql_table - fix a typo

* New module postgresql_table - change columns and params to type str

* New module postgresql_table - fix columns type

* New module postgresql_table - added pg_quote_identifier

* New module postgresql_table - removed unused lib

* New module postgresql_table - query -> queries

* New module postgresql_table - test improvement

* New module postgresql_table - fixed tests for PG 9.0

* New module postgresql_table - fixes

* New module postgresql_table - fixes
2019-03-29 15:51:07 +00:00
David Passante
b0d0a3a2f8 cs_service_offering: Implement customizable compute offers (#54597) 2019-03-29 15:39:54 +01:00
Dag Wieers
2ef0946370
Warn on incorrect use of parameter, and remove fix for now (#54336)
* Fix wrong example, remove strictness and fix tests

It was obvious that (because of an incorrect example) people were using
the **xml** module incorrectly, specifying the `attribute` parameter
where it was not supported (i.e. ignored).

While this functionality would have been useful, it currently returns as
if the information was requested from the parent, so we cannot simply
make it to what would be expected.

Therefor the real solution is to provide a warning when we find
incorrect use, and deprecate this use. Then later we could implement
this functionality correctly.

While troubleshooting this issue, I found that in some cases our
integration tests were not being run when we expected it.

This fixes #53459

* Change warning

* Fix weird sanity test error

* Add a comment to the deprecate-test
2019-03-29 15:13:19 +01:00
Kevin Breit
b3e85b76d7 New module - meraki_static_route (#49271)
* Initial commit for static route module
- Create and query functionality in place today

* Enabled querying both all routes and single route

* Bug fixes and idempotency check
- Requires new idempotency code to validate, blocking on that

* Enabled test cases

* Documentation fixes

* Whitespace fix

* Major improvements based on Dag's commments
- Improved documentation and examples
- Fixed fixed IP assignments and reserved range parameters
- Improved integration tests
- Made check mode work

* Rename str to string in documentation

* Move back to str

* Fix indentation

* Fix documentation for example of fixed_ip_assignments
- Removed default=None for args
2019-03-29 14:27:17 +01:00
Kevin Breit
d16dcb8dbb meraki_device - Support for creating and modifying device notes (#51100)
* Add support for notes

* Add test for notes

* Device notes changes
- Renamed from notes to note
- Modified tests to work

* Comment device test since it only works once

* Remove assertion stanza and move assertion to existing one

* Add version_added to note documentation

* Converted from tabs to spaces

* Added changelog fragment

* Remove changelog file since it's a feature

* Add changelog fragment
2019-03-29 14:26:28 +01:00
Kevin Breit
c30bc24ba9 Create untested task to enable a syslog server (#53125) 2019-03-29 14:24:41 +01:00
Andrey Klychkov
459a8156f5 New module postgresql_membership: Add or remove PostgreSQL roles from groups (#53733)
* New module postgresql_membership: initial

* New module postgresql_membership: fixed sanity
2019-03-29 13:17:56 +00:00
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>
2019-03-29 14:13:59 +01:00
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
2019-03-29 14:12:17 +01:00
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
2019-03-29 13:42:15 +01:00
Jordan Borean
2750f39391
PS AddType - Add the ability to supply custom compile symbols for C# code (#54582) 2019-03-29 19:09:55 +10:00
Zim Kalinowski
bce75824b1
proper name for aks version facts (#54578) 2019-03-29 16:56:40 +08:00
David Passante
7f57d88f00 cloudstack: streamline modules doc (part 5) (#54523) 2019-03-29 09:50:15 +01:00
Matt Clay
8d96af2df5
Use correct python for -c invocations in tests. (#54577)
* Use correct python for -c invocations in tests.
* Only set releasever when available.
2019-03-29 01:19:51 -07:00
Zim Kalinowski
af2e5fc761
Renaming inconsistent module name (#54513) 2019-03-29 14:43:18 +08:00
Matt Clay
20ac19bf2e Test FreeBSD 12.0 with Python 3.x by default. 2019-03-28 21:15:15 -07:00