Commit graph

21735 commits

Author SHA1 Message Date
Matt Clay
dff662fa0f Add plugins to ansible-doc test and fix issues. 2018-05-23 13:10:09 -07:00
Yuji Konishi
9130490048 Fix update parameter (#36022) 2018-05-23 14:36:00 -05:00
flowerysong
e2c1589201 Add cidr_merge filter (#36081) 2018-05-23 14:35:23 -05:00
Shirly Radco
bf53e441b1 Update include_vars.py (#36106)
ignore_files is a list. Example was incorrect.
2018-05-23 14:35:02 -05:00
Lachlan Cooper
d145dfbcf1 rabbitmq_user: Add update_password parameter (#36280)
* Add update_password parameter to rabbitmq_user

Inspiration for this feature is taken from the `user` module.

While `always` is the default in that module, it is not here. We default
to `on_create` to avoid changing existing behaviour.

Resolves #29260

* Update instructions for changing passwords

* Bump version_added as requested

* Check password before changing it

This allows accurate reporting of changed status even though
`rabbitmqctl change_password` doesn't.

* Remove instruction to use 'force' to update password
2018-05-23 14:34:46 -05:00
Colin Nolan
01b3c14e23 consul_kv: support retrieval of values from KV (#37837)
* Adds support to get value from Consul KV.

* Updates documentation.

* Corrects GRL copyright years.

* Resolves PEP 8 issues.

* Changes consul_kv NOT_SET value to `None`.

* Support getting Consul KV values recursively.

* Adds example of retrieving key value.
2018-05-23 14:33:41 -05:00
Brian Coca
73b9892605 add keywords handling to ansible-doc
also add check for sequence of string types before we force a join
2018-05-23 14:09:02 -04:00
Raphaël Droz
606a4b3353 Fix non-HTTPS endpoint (#40601)
Fixes: #36985
2018-05-23 22:42:33 +05:30
metme0145
5f175f2412 Update icinga2_host.py (#40603)
Fix example

+label: docsite_pr
2018-05-23 22:29:30 +05:30
Joshua Smith
a40f6b7c1f Update examples in modules/commands to use proper YAML syntax. (#35692)
* Update examples to use proper YAML syntax.

* Fix syntax error.
2018-05-23 11:50:13 -05:00
Simon
450891a1e7 New Memset module to manage DNS zone records (#40392) 2018-05-23 18:36:57 +02:00
Matt Clay
e5665587c2 Fix PEP 8 issue. 2018-05-23 09:29:37 -07:00
Matt Clay
15b6837daf Add yamllint for plugin docs and fix issues. 2018-05-23 09:19:30 -07:00
Trishna Guha
0b7932db30
add normalize_interface in module_utils and fix nxos_l3_interface module (#40598)
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
2018-05-23 21:42:58 +05:30
S. Veyrié
012003c871 maven_artifact: raise an explicit exception if the .md5 url returns 404 (#40477) 2018-05-23 12:09:23 -04:00
Matt Martz
a5f05c6fc2 [WIP] Start of subelements filter (#39829)
* Start of subelements filter

* Add docs for subelements filter
2018-05-23 11:54:13 -04:00
Ondra Machacek
46fbfd5d53 ovirt: Add support to pass hostname (#40610)
Previously we supported only to pass API URL, now we support also
hostname.
2018-05-23 11:12:46 -04:00
Adam Miller
bc7ff83cd9 parted module not idempotent for esp flag and name (#40547)
* parted module not idempotent for esp flag and name

Fixes #40452

Currently the parted module doesn't take into account names with
spaces in them which leads to non-idempotent transactions on the
state of the system because the name comparison will never succeed.

Also, when the esp flag is set, parted infers the boot flag and the
parted module did not previously account for this. This lead to
non-idempotent transactions as well.

Signed-off-by: Adam Miller <admiller@redhat.com>

* fix unit tests, expected command changed in the patch

Signed-off-by: Adam Miller <admiller@redhat.com>
2018-05-23 11:06:26 -04:00
Lindsay Hill
aa1345dab2 Change Brocade references to Extreme (#40571) 2018-05-23 15:18:37 +01:00
Ryan Brown
ae49f4fd35 Coerce VPC tags from to string types to prevent spurious changed (#40422)
* Coerce VPC tags from to string types to prevent spurious `changed`

* Remove dict comprehension for 2.6 compatibility
2018-05-23 10:17:34 -04:00
pierremahot
3903ca5c8e Fix ios_vlan to correctly identify unmodified config when having long interface names (#40145)
Change the command to get the interface in a vlan "show vlan" => "show vlan brief"
Change the parsing of the return command of the switch.
The return of the ios command is fixed so i cut with fix number of carracter.
Adding looking for the next line to add the forgeted interfaces.
2018-05-23 10:15:54 -04:00
Nathaniel Case
d028a0257a
Change default output of NXAPI to text to match CLI (#40607)
* Default output format for nxapi now 'text'

* Apply json output to both types of input

* Add missing ConnectionError import to cliconf plugins
2018-05-23 10:09:50 -04:00
Brian Coca
4cc4d63289 relocated flatpak 2018-05-23 10:06:44 -04:00
Eric Brown
92a1cb5843 Add missing documentation on return of snmp_facts (#35101)
The snmp_facts module lacked any information on what kind
of data can be expected on the return of successful execution.

This patch expands the docs to included info on return output
including sample data and full descriptions.

Signed-off-by: Eric Brown <browne@vmware.com>
2018-05-23 08:25:49 -05:00
Ken Evensen
fabce98104 Pamd++ (#35709)
* Cleaner, more pythonic, shorter, easier to maintain

* Added validation
2018-05-23 08:24:54 -05:00
Martin Krizek
a3cfe0d72f
apt: don't markmanual if apt-mark is not installed (#40600)
* apt: don't markmanual if apt-mark is not installed

* Add warning
2018-05-23 14:43:18 +02:00
René Moser
f71cea052d
cs_vpc: fix state=present to start vpc (#40587) 2018-05-23 08:53:58 +02:00
Zim Kalinowski
8e38668285 fixing disabled azure sanity tests (#40519)
* fixing azure sanity tests

* fixing sanity

* fixing some tags issues

* removed unnecessary things from managed disk

* fixed location problem

* more sanity fixes

* sanity test fixes

* final sanity fixes?

* final fixes again

* undo changes related to container instance

* removed container instance

* readd again

* fixed stupid mistake

* removed _azure from changes

* one more mistake
2018-05-23 00:49:04 -04:00
eoprede
9bc5dd5d09 fix receive_disable ignore (#40579) 2018-05-22 20:06:17 -07:00
Senya
0a701ff746 Detect separate git dir and set git config path value appropriately
PR #38016

Co-authored-by: Sviatoslav Sydorenko <wk.cvs.github@sydorenko.org.ua>
2018-05-23 00:33:22 +02:00
Gyorgy Nadaban
7d2012fdd7 Implemented support for Repository selection when installing module (#39909)
* Implemented support for Repository selection when installing module

* Fixed AllowClobber check

* Fixing missing AllowClobber argument

* Fixed missing -Force switch

* Test installing package from custom repo

* Added custom repo variables

* Fixed repo registration

* Modified output check

* Modified output check

* Adding debug output

* Modified update handling

* Fixed output check

* Added missing PowerShellGet 1.6.0 install

* Added error handling

* Modified test output check

* Fixing output check

* Fixing output filter

* Implemented registering custom repo

* Fixing registering custom repo

* Fixing registering custom repo

* Fixing registering custom repo

* Tweaked module to shorten execution time

* Removed installing PowerShellGet 1.6.0

* Re-added Install-NugetProvider
2018-05-23 07:36:57 +10:00
Matt Clay
8deced3e04
Fix shebangs and file modes and update tests. (#40563)
* Add execute bit sanity test and apply fixes.
* Add shebang test for `lib` dirs and apply fixes.
* Shebang and execute bit cleanup.
2018-05-22 14:25:36 -07:00
Jordan Borean
f84f3de7c2
powershell: Respect remote_tmp path set by the user (#40210)
* powershell: Respect remote_tmp path set by the user

* Fixed up linting error and typo

* Added changelog
2018-05-23 07:12:32 +10:00
Jordan Borean
070a5557d1
always_run: removed deprecated always_run task option (#40470) 2018-05-23 07:10:36 +10:00
Ewoud Kohl van Wijngaarden
7145dd05b6 foreman: Fix get_option regression (#40534)
d303c0706c introduced a regression because
of a partial port from _options to get_option. This fixes it.
2018-05-22 15:40:51 -05:00
Alexander Bethke
0840cb1fde Add flatpak_remote module (#40189)
* Adding flatpack_remote module

Includes contributions by oolongbrothers: adding documentation fixes, fixing import placements, fix module idempotency, improving error propagation.

* Aligns module with conventions and best practices

For improved robustness and readability; based on feedback by
dagwieers.

* Improves the module documentation

* Aligns copyright statement to conventions

* Renames remote > flatpakrepo_url and reworks documentation
2018-05-22 15:08:16 -05:00
Alexander Bethke
52426b9c9d Add flatpak module (#40286)
* Adding flatpak module

Includes contributions by dagwieers

* Incorporates feedback by dagwieers

* Improves and aligns documentation to conventions

* Makes matching for url more robust
2018-05-22 15:08:07 -05:00
Tim Rupp
29559d8f25
Adds the bigip_gtm_monitor_external module (#40560)
This module can be used to manage GTM external monitors
2018-05-22 12:50:05 -07:00
Tim Rupp
d8d86079c0
Corrects docs for ltm external monitor (#40559)
Examples were incorrect. This fixes them
2018-05-22 12:28:53 -07:00
Tim Rupp
1d2d4a9015
Adds bigip_monitor_external module (#40558)
This module can be used to manage external LTM monitors on a bigip
2018-05-22 12:11:30 -07:00
Robin Lee
d45b044992 Make xenserver_facts actually work (#35821)
* Get the str value of xmlrpc.client.DateTime

* get_all_records should be used instead of get_all

* Facts returned with 'ansible_facts'

* Remove some redundant code

* Add cheese as maintainer

* Add changelog entry
2018-05-22 13:31:35 -04:00
Sam Doran
d5dbd8c76d
EdgeOS module improvements (#39530)
* Update docs and use to_text on strings

* Add warning to use network_cli
2018-05-22 12:22:18 -04:00
Nathaniel Case
e8d02a3a0f
Search all assigned ipv6 addresses instead of just the first (#40533)
* Search all assigned ipv6 addresses instead of just the first

* Add test for idempotency with multiple ipv6 addresses assigned
2018-05-22 12:00:16 -04:00
Ryan Brown
858b1c277b
[docs] Update ec2 module to use wait_for_connection instead of wait_for (#40171) 2018-05-22 11:21:04 -04:00
Brian Coca
0339c8037b use correct object in error
fixes #40453
2018-05-22 11:10:57 -04:00
Matt Martz
ea176427b4 Group logic detecting user, ensure rsync_opts is a list if omitted. Fixes #40483 2018-05-22 11:00:54 -04:00
Nathaniel Case
28f19fc7b3
Fix persistent timeout definitions (#40540) 2018-05-22 11:00:08 -04:00
Alex Stephen
90588f4970 New module: GCP Compute Firewalls (#39032) 2018-05-22 10:55:12 -04:00
Alex Stephen
fd3ed6660e New module: GCP Compute Forwarding Rules (#38613) 2018-05-22 10:53:58 -04:00
Alex Stephen
c9b445c182 New module: GCP Compute Global Address (#38614) 2018-05-22 10:53:41 -04:00
Alex Stephen
d3222a97c8 New module: GCP Compute Global Forwarding Rules (#38615) 2018-05-22 10:53:12 -04:00
Alex Stephen
886f930e59 New module: GCP Compute Images (#38616) 2018-05-22 10:52:50 -04:00
Alex Stephen
41c9ba08a4 New module: GCP Compute Ssl Certificates (#38620) 2018-05-22 10:44:44 -04:00
Alex Stephen
43afb5465f New module: GCP Compute Instance Groups (#38617) 2018-05-22 10:39:49 -04:00
Alex Stephen
05c1257aeb New module: GCP Compute Target Pools (#38623) 2018-05-22 10:38:07 -04:00
Alex Stephen
e09c661ae5 New module: GCP Compute Url Maps (#38625) 2018-05-22 10:36:51 -04:00
Alex Stephen
e4bbcbbdae New module: GCP Compute Instance Group Managers (#38934) 2018-05-22 10:36:20 -04:00
Alex Stephen
79b8ed8622 Adding support for GCP Compute Target Ssl Proxys (#39033) 2018-05-22 10:31:45 -04:00
Ken Celenza
dd02a4e943 create cisco type 5 filters (#39901) 2018-05-22 13:35:54 +01:00
Stéphane Travassac
c29b03e77b VMware: Fix file operation to work with ESXi directly (#40148)
Now, file_operation module can be used with both vCenter and Standalone ESXi server.
2018-05-22 17:40:47 +05:30
Abhijeet Kasurde
da79989e70
VMware: vmware_guest Documentation update (#38377)
This PR refactors vmware_guest module

- VMware: Documentation update
- Elaborate more on effects of state on virtual machine.
- Specify 'force' option usage.
- Formatting
- add review comments

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2018-05-22 17:31:20 +05:30
Matthew Stone
c0b264d7b7 Adding slxos_vlan module (#39197)
* Adding slxos_vlan module
2018-05-22 11:43:46 +01:00
Matthew Stone
683ab9bb9f Adding slxos_l3_interface module (#39320)
* Adding slxos_l3_interface module

* Corrected return values

The returned IPv4 address has a prefix length, not a subnet mask
2018-05-22 11:41:25 +01:00
Deric Crago
3744b69a40 simplified DistributedVirtualSwitch namespacing (#40191) 2018-05-22 15:38:31 +05:30
Marcel Arns
26ea64cdea New module: heroku_collaborator (#39001) 2018-05-22 11:50:53 +02:00
saichint
97070c9688 fix nxos_system issues (#40347) 2018-05-22 14:19:34 +05:30
Ben Hagen
7eb98660a4 digital_ocean_domain: fix do not fail if domain already is absent (#40446) 2018-05-22 07:59:06 +02:00
Tim Rupp
9b22438a9b
Adds bigiq utility license module (#40518)
This module can be used to manage utility licenses on a BIG-IQ
2018-05-21 20:18:41 -07:00
Tim Rupp
4689de9db8
Fixes bigiq doc error (#40517)
Corrects the return values for a bigiq module
2018-05-21 19:55:51 -07:00
Matt Clay
cfe7de10ef Update Ansible release version to 2.6.0dev0. 2018-05-21 19:29:14 -07:00
Matt Clay
c98043a4c0 New release v2.6.0a1 2018-05-21 17:26:16 -07:00
Jordan Borean
1ac180c74d
winrm: source user from options than remote_user (#40467)
* winrm: source user from options than remote_user

* fixed up mock for kerberos import

* Added changelog fragment

* get hostname from option as well
2018-05-22 09:36:48 +10:00
Matt Davis
e4edb2842a 2.6 changelog gen/version/root dir cleanup (#40421)
* patched in changelog gen stuff from stable-2.5
* Makefile updates
* release.py as single-source-of-truth
* Remove obsolete ansible-core-sitemap.xml file.
* Move ROADMAP.rst into README.rst.
* dynamic rpm changelog, zap old deb/rpm changelogs
* fix changelog in MANIFEST.in
* Remove obsolete hacking/update.sh script.
* Remove ref to deleted authors script.
* Remove ref to removed module-formatter script.
* Update headings to match script names.
* MANIFEST.in cleanup
* removed RELEASES.txt and versions.yml
* removed obsolete release generation playbook/bits (not used since 2.5)
* misc Makefile cleanup
* speculative changes to DEB versioning
* allow override of DEB_VERSION/DEB_RELEASE
2018-05-21 16:14:53 -07:00
Nathaniel Case
eb818df1ec
Ios test fixes (#40503)
* Return messages generated from edit_config to module

* This does not seem to work that way

* Change test IP addresses to not conflict with device config
2018-05-21 17:51:21 -04:00
Jordan Borean
db195831fd
win_environment: Added explicit check for null, empty string with state=present (#40468)
* win_environment: Added explicit check for null, empty string with state=present

* Added changelog fragment
2018-05-22 06:45:33 +10:00
Strahinja Kustudic
32d6a354d7 postgresql_user: set encrypted as default and fix empty password reporting changed (#36931)
* Set encrypted as default and fix empty password reporting changed

* Starting with Postgres 10 `UNENCRYPTED` passwords are removed and
because of that this module fails with the default `encrypted=no`.
Also encrypted passwords are suported since version 7.2
(https://www.postgresql.org/docs/7.2/static/sql-createuser.html) which
went EOL in 2007 and since 7.3 it is the default. Because of this it
makes a lot more sense to make `encrypted=yes` the default. This won't
break backward compatibility, the module would just update the user's
password in the DB in the hashed format and everything else will work
like before. It's also a security bad practice to store passwords in
plain text. fixes #25823
* There was also a bug with `encrypted=yes` and an empty password always
reported as changed.
* Improved documentation for `encrypted`/`password` parameters, and
removed some obsolete notes about passlib.

* Fix clearing user's password to work with all versions of Postgres

* Add tests for clearing the user password

* Fix documentation atfer rebase

* Add changelog fragment
2018-05-21 14:49:44 -05:00
Brian Coca
062f0444a1 remove extra ) 2018-05-21 15:19:13 -04:00
Brian Coca
ee95b71f7b reset_connection is not run_once 2018-05-21 15:19:13 -04:00
Bruno Inec
b845db0169 Explicit availability of 'null' timeout in expect (#40429) 2018-05-21 12:32:06 -05:00
Abhijeet Kasurde
3b14d2b745 Correct doc for cache plugin
Section is a part of ini, so removing it as separate key.

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2018-05-21 13:29:03 -04:00
Adrian Lopez
7255b6a151 Fixes #29818: chkconfig command is not daemonized, uses run_command()
In the last commit I modified the code to run commands when they are
daemonized. But the execution of "chkconfig" is not daemonized so it
uses "self.module.run_command(cmd)".

This commit set the default localize to allow proper screen scraping of
chkconfig command.
2018-05-21 12:54:18 -04:00
René Moser
516e18f4b8
cloudstack: fix query tags by resourceid (#40482) 2018-05-21 17:16:44 +02:00
Nathaniel Case
483df13626 Fixing issues with httpapi (#40388)
* I seem to have forgotten the back half of tests

* Set http timeout from persistent_command_timeout

* Tweak URL generation and provide URL on error

* Push var_options to connection process

* Don't wait forever if coming from persistent

* Don't send the entire contents of variables to ansible-connection
2018-05-21 15:58:35 +01:00
Sam Doran
1c20029694
Fix ctrl+c in pause module and add tests (#40134)
* Fix all cases with pause and ctrl+c
 - naked:
	- pause:
 - with prompt
	- pause: prompt=hi
 - time wait
	- pause: seconds=60
 - time wait with prompt
	- pause: seconds=60 prompt=hi


Fixes #35372

* Use curses to control stdout
* Use curses to clear lines on interactive input
* Validate input for echo parameter and fail nicely if invalid
* Add integration tests for pause module using pexpect
* Use try except when trying to determine erase sequence to account for lack of TTY in containers in tests
* Improve output validation for regular paus test
* Accept two digit precision for pause length in test
* Check for seconds when seconds is specificed, minutes when minutes is specified
* Add test for no TTY mode

Co-authored by: Toshio Kuratomi <a.badger@gmail.com>
Co-authored by: Brian Coca <brian.coca+git@gmail.com>
2018-05-21 10:04:43 -04:00
Antoine Catton
39f9d3e4a6 Add the ability to specify an install_dir to the gem module (#38195)
* Add the ability to specify an install_dir to the gem module

* Add GEM_HOME when installing a non-global gem

* Add tests for custom gem path

* Fix sanity tests

* Add changelog entry

* Rebase and add tests for incorrect options

Co-authored by: Antoine Catton <devel@antoine.catton.fr>
2018-05-21 09:55:43 -04:00
Sumit Jaiswal
fc8663edc0
Integration tests for Infoblox 2.5 modules (#40344)
* Update nios.py

* Update nios.py

* Update nios.py

* nios lookup errors out when there are no results #37970  Open	

Indentation failure issue resolved

* Returning empty list instead of None

In case of no results, res will be returned as an empty list instead of None (implementing ganeshrn comment)

* infoblox ipv6 support changes

* infoblox ipv6 support changes

* for fixing pep8 errors

* moving ipaddr check to utils

* adding ipv6addr check

* increasing space to resolve pep8 error

* modified the playbook examples to valid ones

* Update nios_network.py

* integration tests for nios 2.5 modules

* modification done in existing integration nios testcases

* dns_view nios module tc

* host_record nios module tc

* network nios module tc

* network_view nios module tc

* zone nios module tc

* changes to fix shippabe errors for PR 40344

* PR40344 shippable fix

* PR40344 shippable fix

* PR40344 shippable fix

* PR40344 shippable fix

* PR40344 shippable fix

* PR40344 shippable fix

* PR40344 shippable fix

* PR40344 shippable fix

* PR40344 shippable error fix

* 40344 shippable fix

* 40344 shippable fix

* 40344 shippable fix

* 40344 shippable fix

* 40344 shippable fix

* 40344 shippable fix

* PR40344 shippable error fix for block comment should start with '# '
2018-05-21 17:04:20 +05:30
Jared Hocutt
44d9dd2c77 Fix example in ipa_dnszone module (#40443)
The ipa_dnszone module had a typo in the examples where "ipa_dnsrecord"
was being used instead of "ipa_dnszone".
2018-05-20 16:28:02 +05:30
Tim Rupp
1190591e3c
Adds the bigip_gtm_global module (#40430)
This module can be used to manage the global GTM settings on a BIGIP
2018-05-18 20:48:09 -07:00
Tim Rupp
510995bd83
Adds remaining fqdn params to bigip_node (#40427)
This patch adds params for auto_populate, address type, up interval
and down interval params to bigip node
2018-05-18 19:14:07 -07:00
Chris Archibald
8b5f34e110 Add Na_ontap_broadcast_domain module. (#39753)
* add first module

* fix case

* Create na_ontap

* Fix small pep8 errors

* Fixes for issues found by Amit

* fixes for amit

* fix doc

* get doc to compile
2018-05-18 17:17:01 -07:00
Tim Rupp
5af91ef407
Adds wait parameters to bigiq applications (#40420)
The wait parameter allows the module to wait or not wait when
an application is created. By default the modules will wait.
2018-05-18 13:51:16 -07:00
Tim Rupp
1492414165
Fixes password missing in bigip_device_trust (#40414)
The documentation did not match the code. This patch fixes the code
to correctly fallback the peer password if necessary
2018-05-18 11:58:42 -07:00
Daniel Andrei Mincă
265a51ab93 format module values in gce_net module documentation (#40047)
* format code in gce_net module

The values passed to the module weren't being highlighted properly in
the documentation page.

As a result, use markup code format for the values provided in order to
be spotted easily on the page.

Signed-off-by: Daniel Andrei Minca <mandrei17@gmail.com>

* separate phrases

Signed-off-by: Daniel Andrei Minca <mandrei17@gmail.com>

* apply review fix for module options

According to http://docs.ansible.com/ansible/devel/dev_guide/developing_modules_documenting.html#formatting-functions

Signed-off-by: Daniel Andrei Minca <mandrei17@gmail.com>
2018-05-18 16:46:49 +01:00
Simon
fb6ae90f60 Memset: initial module, integration tests, module_utils and supporting documentation. (#40071)
*  * Memset:
   * module_utils and associated documentation.
   * module to manage DNS zones.
   * integration tests to run against Memset's API.

* * memset.py:
  * remove import of requests from memset.py in favour of internal Ansible modules.
  * import necessary Ansible modules for request and response handling.
  * create a response object in order to retain a stable interface to memset_api_call from existing modules.
  * rework memset_api_call to remove requests.
* memset_zone.py:
  * improve short description to be more verbose.
  * ensure all imports directly follow documentation.
  * remove any reference to requests.
  * correct keyerror carried over from elsewhere.

* remove dependency on requests from documentation string

* disable integration tests until we have a cleanup method available
2018-05-18 10:45:38 +01:00
Deepak Agrawal
9e3ad96fa9
rename network_get network_put modules to net_get net_put (#40381) 2018-05-18 14:41:47 +05:30
Ganesh Nalawade
de2c1dc241
Fix netconf get_config lock/unlock (#40378)
Lock/unlock the datastore that is given as input for
instead of default to `running`
2018-05-18 13:10:28 +05:30
Martin Krizek
a996d4836a
rhsm_repository: use C locale for out/err scraping (#40338) 2018-05-18 07:55:37 +02:00
Tim Rupp
484b86a643
Adds the virtual argument to bigip_policy_rule (#40373)
This patch allows the module ot manage forwarding actions to virtual
servers in addition to the existing pools argument
2018-05-17 21:08:20 -07:00
Tim Rupp
f87cda8a54
small fixes and additions to bigip_virtual_address (#40362)
* Updated parameter names to match updated features in BIGIP
* Added support for route domains
2018-05-17 20:45:53 -07:00
Nathaniel Case
e9d7fa0418
HTTP(S) API connection plugin (#39224)
* HTTPAPI connection

* Punt run_commands to cliconf or httpapi

* Fake enable_mode on eapi

* Pull changes to nxos

* Move load_config to edit_config for future-preparedness

* Don't fail on lldp disabled

* Re-enable check_rc on nxos' run_commands

* Reorganize nxos httpapi plugin for compatibility

* draft docs for connection: httpapi

* restores docs for connection:local for eapi

* Add _remote_is_local to httpapi
2018-05-17 18:47:15 -04:00
Adam Miller
cc61c86049
sysvinit service module (#34962)
* sysvinit service module

Signed-off-by: Adam Miller <admiller@redhat.com>
2018-05-17 17:32:27 -05:00
Toshio Kuratomi
3760cc3a7d Fix python-2.4ism that was still present in basic.py's use of tempfile 2018-05-17 15:24:56 -07:00
Toshio Kuratomi
0442efd33a Move rewriting of path earlier in the argument handling as other things depend on the path 2018-05-17 15:24:56 -07:00
Toshio Kuratomi
021f33e063 original basename minus src 2018-05-17 15:24:56 -07:00
Toshio Kuratomi
20b9ca6e7c Rename original_basename parameter in various file-related modules
original_basename is a private internal parameter so name it
_original_basename to reflect that it is internal.
2018-05-17 15:24:56 -07:00
Toshio Kuratomi
cd4d0069ba Reorganize ensure_directory to make things clearer
* value of file_args['path'] is now more clear
* We already have b_path so reuser that
* Add comments
2018-05-17 15:24:56 -07:00
Toshio Kuratomi
7d2ec56a99 Correct bug reporting the diff when state=touch as absent 2018-05-17 15:24:56 -07:00
Toshio Kuratomi
c8ac02d6f2 Emit a warning when src is used with a state where it should be ignored 2018-05-17 15:24:56 -07:00
Nathaniel Case
90770a290f Don't rewrite remote paths when remote is secretly local (#40259)
* Don't rewrite remote paths when remote is secretly local

* Remote overriding is configurable in connection

* Use c.DEFAULT_LOCAL_TMP instead of remote_tmp

* Remove remote_is_local from ConnectionBase

* remote_is_local->_remote_is_local

* Add warning signs to _remote_is_local and explanatory comments to its use
2018-05-17 23:21:30 +01:00
Scott Buchanan
b12cf754f6 1Password lookup plugin (#37207)
* add pytest_cache to gitignore

* onepassword lookup plugin

* fix linter/style test complaints

* second pass at making pycodestyle happy

* use json module instead of jq

* update copyrights, license & version added

* fix python2 compatibility

* doh. fix spacing issue.

* use standard ansible exception

* remove potentially problematic stdin argument

* actually call assertion method

* add support for top-level fields

* make vault uuids pedantically consistent in fixture

* fix new style issues

* ability specify section & correct case handling

* improve error handling

* add onepassword_raw plugin

* Add maintainer info

* Move common code to module_utils/onepassword.py

* Load raw data JSON data for easier use in Ansible

* Put OnePass class back inside lookup plugin

There is no good place for sharing code across lookups currently.

* Remove debugging code in unit tests

* Patche proper module in raw unit tests

* Add changelog entry

Co-authored-by: Scott Buchanan <sbuchanan@ri.pn>
2018-05-17 17:29:47 -04:00
Mário Santos
7e2087731e Add new OpenStack module for changing metadata of compute instances (#19113)
* Add new OpenStack module for changing metadata of compute instances

* Add missing RETURN documentation

* Fix API calls to match shade's implementation.

API was changed in the following PR (openstack-infra/shade):
https://review.openstack.org/#/c/319395

* Replace type by isinstance when type checking

* Add ANSIBLE_METADATA

Signed-off-by: Mário Santos <mario.rf.santos@gmail.com>

* Bump the ansible version

Signed-off-by: Mário Santos <mario.rf.santos@gmail.com>

* Add support for check_mode

Signed-off-by: Mário Santos <mario.rf.santos@gmail.com>

* Fix sanity tests

Signed-off-by: Mário Santos <mario.rf.santos@gmail.com>

* Force the meta parameter to be a string

Signed-off-by: Mário Santos <mario.rf.santos@gmail.com>

* Use short GPL license

Signed-off-by: Mário Santos <mario.rf.santos@gmail.com>

* Change meta argument to dict

Signed-off-by: Mário Santos <mario.rf.santos@gmail.com>
2018-05-17 17:24:28 -04:00
Artem Goncharov
db786b846f fixes issue 39472: (#40341)
With python 3.6 spwd.getspnam returns PermissionError instead of
KeyError if user does not have privileges
2018-05-17 17:22:40 -04:00
bengerman
82f6f08712 allow non-integer values in /etc/default/passwd to mirror solaris behavior 2018-05-17 16:57:58 -04:00
René Moser
de8b6b55f7
cs_vpc: implement state=started (#40319) 2018-05-17 22:42:53 +02:00
Alex Stephen
6ac2045db8 Adding support for GCP Compute Target Http Proxys (#38622) 2018-05-17 16:42:19 -04:00
Alex Stephen
22ccbf5cbb Adding support for GCP Compute Target Tcp Proxys (#38624) 2018-05-17 16:42:10 -04:00
Alex Stephen
afdbdd99ed Adding support for GCP Compute Target Https Proxys (#38908) 2018-05-17 16:34:20 -04:00
Adam Miller
98a198a777
Handle incorrect data type in list lookup plugin (#35483)
handle incorrect data type in list lookup plugin
Fixes #35481
test to ensure that loops properly handle incorrect datatypes

Signed-off-by: Adam Miller <admiller@redhat.com>
2018-05-17 15:29:36 -05:00
Ben Berry
6a4f3fb729 S3 versioned lifecycle (#40161)
* - add tests for s3_lifecycle
- fix a bug comparing transitions with different storage_types

* make s3_lifecycle work with boto3

* add noncurrent version lifecycle rules
2018-05-17 15:07:40 -04:00
Martin Krizek
ca3390377a
redhat_subscription: C locale for stdout scraping (#40165) 2018-05-17 20:44:06 +02:00
Sam Doran
c9d3bb59a4 Do not join flag parameters in iptables module (#36658)
* Do not join flag parameters

This put a comma between every character of the tcp flag parameters, resulting in a bad iptables command.

Fixes #36490

* Use suboptions to ensure tcp_flags options are lists

* Add unit tests for tcp_flags

* Add example of how to use tcp_flags
2018-05-17 13:53:51 -04:00
Sam Doran
13aff08748 Add better error messages and checking to known_hosts (#38307) 2018-05-17 13:53:40 -04:00
Marcus Watkins
279cf596dc New Module: gitlab_hooks module and related tests (#40096)
* Added gitlab_hooks module and related tests

* Fix sanity check issues

* Refactor to use common util method, add check_mode support

* Fix module shebang
2018-05-17 13:52:48 -04:00
Marcus Watkins
7d87995207 New Module: gitlab_deploy_key and related tests (#40097)
* Added module gitlab_deploy_key and related tests

* Fix sanity check issues

* Refactor to use common util method, add check_mode support

* Fix module shebang
2018-05-17 13:52:40 -04:00
Sloane Hertel
571c183f59
Fix failing aws_ses_identity integration tests (#39560)
* Fix failing aws_ses_identity integration tests

Reduce boilerplate with yaml anchor

* remove unstable test alias

* Update feedback forwarding check to use desired state rather than
repeated API calls.
2018-05-17 13:45:02 -04:00
Dag Wieers
0fba72ce3c uri: Add form-urlencoded support to body_format (#37188)
* uri: Add form-urlencoded support to body_format

This PR adds form-urlencoded support so the user does not need to take
care of correctly encode input and have the same convenience as using
JSON.

This fixes #37182

* Various fixes

* Undo documentation improvements

No longer my problem

* Fix the remaining review comments
2018-05-17 13:18:18 -04:00
Sijis Aviles
0f16b26080 docs: Suggest get_url or uri for file checksum validation (#40087)
Fixes #13665
2018-05-17 11:52:33 -04:00
Ryan Brown
dda7d9e704
[AWS] Add Ansible Version to botocore user agent string (#39993)
Pull `config` out if it was provided to boto3_conn and add the useragent string
2018-05-17 11:41:14 -04:00
Brian Coca
677fe1076d
User unexpire (#39758)
* Allow negative values to expires to unexpire a user

Fixes #20096

(cherry picked from commit 34f8080a19)
(cherry picked from commit 54619f70f4)
(cherry picked from commit 8c2fae27d6)
(cherry picked from commit db1a32f8ca)

* tweaked and normalized

 - also added tests, made checking resilient
2018-05-17 11:34:13 -04:00
Pierre-Louis Bonicoli
19356c03e8 filesystem tests: update ocfs2 fs size on Trusty
Using Ubuntu 14.04, test fails because 'blkid' < 2.21 doesn't recognize
'ocfs2' filesystem smaller than 108Mo:
6baa150398

filesystem: fix MKFS_FORCE_FLAGS for ocfs2

mkfs.ocfs2 -F won't work because mkfs.ocfs2 asks for a confirmation:

    $ mkfs.ocfs2 -F img
    mkfs.ocfs2 1.6.4
    Cluster stack: classic o2cb
    Overwriting existing ocfs2 partition.
    WARNING: Cluster check disabled.
    Proceed (y/N):

The undocumented 'x' switch must be used too.
2018-05-17 11:18:18 -04:00
Luc
51af25bf60 remove bad lines
add new line and update choice documentation
adding description for ocfs2 support
use correct variable ansible_distribution to test ocfs2 with Debian
distribution
use ansible_os_family for Debian
increase ocfs2 fs size to 20M (minimal size 11 instead of 10M)
2018-05-17 11:18:18 -04:00
lchantre
4f86bec977 Update filesystem.py
add ocfs2 support for module filesystem
Update setup.yml
delete trailing spaces
add ocsfs2 defaut var
Install ocfs2-tools for all linux
Testing ocfs2 on for Ubuntu - restrict blkid to be be done
2018-05-17 11:18:18 -04:00
Mike Wiebe
63e16431b7 Fix legacy Nexus 3k integration test and module issues. (#40322)
* Add setup ignore_errors for nxos_config test

* Fix parse_fan_info for n3k

* Skip bidir tests for N3k

* Omit vni config for n3k

* Skip unsupported nxos_vrf_af test on N3K

* Add legacy N3K platform tag
2018-05-17 20:29:00 +05:30
Anil Kumar Muraleedharan
1cb4619c9a Modifying cnos-facts, cnos_command and cnos-config in line with the design followed in Ansible. Adding unit test cases for these modules. Added plugins to support them. (#39955)
* Modifying cnos-facts, cnos_command and cnos-config in line with the design followed in Ansible. Adding unit test cases for these modules. Added plugins to support them.

* Removing doc fragment conflicts with other modules

* Replacing show with display
2018-05-17 10:06:24 -04:00
Ganesh Nalawade
30f992f260
Add netconf_get module (#39869)
* Add netconf_get module

Implements part-1 of proposal #104
https://github.com/ansible/proposals/issues/104

*  Add netconf_get module
*  Refactor `get`, `get_config`, `lock`, `unlock`
   and `discard_changes` netconf plugin api's
*  Add netconf module_utils file which netconf module
   related common functions
*  Refactor junos and iosxr netconf plugins

* Fix source option handling

* Fix review comments

* Update botmeta file

* Update review comments and add support for lock

* Lock update fix

* Fix CI issue

* Add integration test and minor fixes

* Fix review comments

* Fix CI failure

* Fix CI issues

* Fix CI issues

* Fix review comments and update integration test

* Fix review comments

* Fix review comments

* Fix review comments

Fix reveiw comments
2018-05-17 17:38:12 +05:30
suacide24
4c0ceaea3d changed accportgrp to accbundle (#40104)
* changed accportgrp to accbundle

* fixed shippable complaints

* changed policy_group_type to interface_type
2018-05-17 13:11:31 +02:00
René Moser
1f0c2ca6c9
cs_instance_facts: add host return (#40307) 2018-05-17 12:17:49 +02:00
Peter Farmer
912e07a036 cloudstack: added fetch_list=True where appropriate (#40233) 2018-05-17 12:16:43 +02:00
Rafael
44eaa2c007 opennebula: new module one_host (#40041) 2018-05-17 10:10:49 +02:00
Thad Guidry
98579029d7 small grammar improvements to add clarity (#40157) 2018-05-17 14:09:32 +10:00
Martin Krizek
b116eaa485 Clarify in docs that end_play affects all hosts (#40235) 2018-05-17 13:53:46 +10:00
Zim Kalinowski
db8f10e9cb Improved scaleset facts (#39722)
* improved scaleset facts

* scaleset facts fix some errors

* adding version_added for format param

* trying to break lines

* fixed syntax

* small code restructuring

* fix syntax

* fixed now

* add new test to scaleset / scaleset facts

* make scaleset test more clear

* temporarily comment out...

* try to retrieve scaleset facts

* try to add postfix

* fixed mistake

* fixed problem when no loadbalancer attached

* fixed another bug

* fixed sanity and a few other

* fixed pep8

* another try

* changed ansible to curated

* updated tests

* updated example and a few other mods

* small fixes

* removed unnecessary pass

* removed some items from ignore.txt

* remove file added by mistake
2018-05-17 13:28:30 +10:00
Daniel-Sanchez-Fabregas
ee2adb45a8 Adding module win_domain_computer (#35954)
* Adding module win_domain_computer

This module is a wrapper of powershell *-ADComputer commands.
The main use case is to add non-windows computers to Active Directory
through a bridge windows computer.

* Replace `Set-Attr`

* Fix case insensitive comparisons

* Add omitted parameters in cmdlets

* Enhance module documentation

* Simplify `state` as case insensitive.

* Simplify try catch

* Fix indentation

* Make message errors more descriptive.

* Specify type in boolean parameters

* Keep parameter ingestion together

* Delete superfluous resultobj

* Workaround failing Erroraction

* Add target info in error

* Cosmetic changes

* Fix up Fail-Json to use correct message param
2018-05-17 13:06:01 +10:00
Will Thames
57c801c34f RDS: split into more sensible modules
RDS instance and snapshot facts modules
Move common code into module_utils/rds.py

This work is a precursor to new rds_snapshot
and rds_instance modules

Improve rds_snapshot_facts to latest AWS standards

Improve exception handling, pagination etc.

Version added

Add clustered snapshot facts

Add proper RETURN information for snapshots and cluster_snapshots

pep8

Co-authored-by: Michael De La Rue <jababubic.margoteen@spamgourmet.com>
2018-05-16 22:48:57 -04:00
Will Thames
42368ce310 rds_instance_facts module
Create rds_instance_facts module using boto3.

Create common rds.py module_util library to be used by
rds_instance_facts and future RDS modules.

rds_instance_facts: use latest AWS helper methods

* Use `module.client` with `retry` to create AWS connection
* Return tags, using AWSRetry helper to backoff
* Use paginator to describe DB instances
* Further improve exception handling
* Fix RETURN documentation

update version_added

Co-authored-by: Michael De La Rue <jababubic.margoteen@spamgourmet.com>
2018-05-16 22:21:47 -04:00
Jordan Borean
2f70360698
Add windows module for changing the hostname (#40295)
Co-authored-by: Ripon Banik <riponbanik@users.noreply.github.com>
2018-05-17 11:41:37 +10:00
Jordan Borean
5c39c3b2d1
Module basic.py to create parent dirs of tmpdir if needed (#40201)
* Module basic.py to create parent dirs of tmpdir if needed

* Added warning to dir creation

* Assert if make_dirs was called or not in unit tests
2018-05-17 09:52:46 +10:00
jctanner
5df370243d
Fix case (#40272)
* Github logins are case sensitive

* Fix login case across all modules
2018-05-16 19:51:55 -04:00
Sertaç Özercan
6e4a2b17de [new module] Managed Azure Container Service (AKS) (azure_rm_aks) (#35888)
* add aks module and integration tests

* linting

* update tests

* sanity check

* make some changes to AKS module

* make integration test work

* add fact

* add resource_group name

* add fact test

* fix test

* fix test

* linting

* changed line endings for facts

* output kubeconfig

* Update azure_rm_aks.py

* update integration test aliases

* update aliases

* add cloud_environment and auth_source to args

* Fix comments from Jborean93 (#3)

* update

* fix

* fix

* fix

* fix

* update doc

* fix
2018-05-16 16:08:27 -07:00
Jordan Borean
837aada4a8 win_updates: fix typo with download failure and whitelist on multiple updates (#40283) 2018-05-16 18:04:58 -04:00
Adam Patt
223a4c0685 Fixes #19392: allow commands to be specified as lists. new syntax is documented as well. (#40261)
* Fixes #19392: allow commands to be specified as lists.  new syntax is documented as well
2018-05-16 13:37:39 -07:00
Tim Rupp
b325e9900c
Adds BIGIQ application HTTPS WAF module (#40270)
This module can be used to manage HTTPS WAF applications on a BIGIQ
2018-05-16 12:49:21 -07:00
Tim Rupp
1f2cfb0a91
Adds the BIGIQ application HTTPS offload module (#40269)
This module allows you to manage HTTPS offload applications on a BIGIQ
2018-05-16 12:26:59 -07:00
Tim Rupp
5e7878a6a1
Adds various fixes for f5 modules (#40208)
* Adds stty expansion for cli commands
* minor fixes
* Make bigiq rest client work correctly
2018-05-16 12:14:12 -07:00
John Sutterfield
d5a5e37fcf Add fallback check for IAM role temp creds (#40240)
* Add fallback check for IAM role temp creds
2018-05-16 14:27:49 -04:00
Toshio Kuratomi
6227c2ac75
More file refactoring (#40114)
* Set src in the state functions rather than the toplevel

A good API should only require passing one version of a piece of data
around so do that for src

* Move the rewriting of path into additional_parameter_handling

When the path is a directory we can rewrite the path to be a file inside
of the directory

* Emit a warning when src is used with a state where it should be ignored
2018-05-16 10:41:11 -07:00
Ricardo Carrillo Cruz
5ae77337a1
Rename persistent_connection_timeout to connect_timeout in INI section (#40260) 2018-05-16 19:01:24 +02:00
Toshio Kuratomi
ca4147f2cc Fixes #34893 (#40166)
Fixes several bugs exposed in #34893
* Fixes relative path handling in copy so that it splits directories and
  reconstructs the correct file path
* Return failed in the proper circumstances
2018-05-16 11:09:32 -05:00
Fabian von Feilitzsch
4373b155a5 Move k8s modules to dynamic backend (#39632)
* Move k8s modules to dynamic backend
2018-05-16 10:57:36 -05:00
Tim Rupp
4f19e6f436
Adds the BIGIQ FastL4 UDP application module (#40257)
This module allows you to manage FastL4 applications on a BIGIQ
2018-05-16 07:53:54 -07:00
Tim Rupp
398c57e70d
Adds the BIGIQ application fastl4 tcp module (#40216)
This module allows you to manage FastL4 TCP Applications on a BIGIQ
2018-05-16 07:39:41 -07:00
Tyler Bigler
db4ae20e8b ios_command: Correct answer example and consolidate docs on command param. (#40158)
* Correct answer example as 'c' cancels, not confirms. Moved command note to be in line with command docs.

* Correct example to escape square brackets. Remove '\r' mention as it does not get passed correctly.

* Add carriage return example since it works with double quotes.

* Remove colon which was breaking docs rendering.
2018-05-16 15:39:07 +01:00
Anil Kumar Muraleedharan
f60731e27e Lenovo cli expansion - Modify command acronyms to full commands (#40218)
* Changing Lenovo Inc to Lenovo and update License file to be consistent.

* Editing cli commands to expanded form. Changing username and password fields as per Ansible standards.
2018-05-16 15:25:58 +01:00
Tyler Bigler
39bed45baf ios_facts: Add check to skip lldp neighbors if lldp doesn't exist or isn't enabled. (#40109)
* Add check to skip lldp neighbors if lldp doesn't exist or isn't enabled.

* Re-enable check_rc on ios' run_commands
2018-05-16 09:33:57 -04:00
Ricardo Carrillo Cruz
62e1c14edc
Pull persistent connection parameters via get_option (#39367)
* WIP Pull persistent connection parameters via get_option

* Fix pep8

* Add use_persistent_connection setting to paramiko_ssh plugin

* Add vars section to persistent_command_timeout setting and prevail provider values over config manager

* Use persistent_command_timeout on network_cli instead of timeout

* Fix unit tests

If we don't call loader to get network_cli, then _load_name is never
set and we get KeyError.

* Pull persistent_command_timeout via config  manager for ios connection local

* Pull persistent_command_timeout via config manager on connection local
2018-05-16 14:59:01 +02:00
Ganesh Nalawade
865f2c5990
Fix junos_config confirm timeout issue (#40238)
* Fix junos_config confirm timeout issue

* Fix unit test
2018-05-16 18:14:23 +05:30
Trishna Guha
979f1e5ed1
save_snapshot_locally nxos_snapshot (#40227)
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
2018-05-16 14:59:23 +05:30
Deepak Agrawal
86c945a628
network_put and network_get modules (#39592)
* Initial commit

* Socket Timeout and dest file handler

* sftp handling

* module name change as per review

* multiple thread tmp file overwite problem

* Integration test suite for network_put

* add additional testcase for dest argument

* fix pylint/pep8/modules warnings

* add socket timeout for get_file

* network_get module

* pep8 issue on network_get

* Review comments
2018-05-16 14:38:43 +05:30
Yuwei Zhou
05c4f5997e azure_rm_securitygroup cannot create rules that allow IP address prefixes (#40070)
* support mutilple ip prefixes

* fix lint

* order is no matter

* remove alias

* fix
2018-05-16 16:28:14 +08:00
Tim Rupp
5ae499466b
Adds BIGIQ Fast HTTP module (#40213)
This module can be used to manage Fast HTTP applications on a BIGIQ
2018-05-15 22:43:40 -07:00
Tim Rupp
576ad58b0f
Adds the BIGIQ application HTTP module (#40211)
This module can be used to manage http applications on a BIGIQ
2018-05-15 22:20:07 -07:00
vigiroux
0b3ed626b3 empty lines in csvfile means row has no items in list; check row len first. (#40089) 2018-05-15 17:26:53 -05:00
Tobias Wolf
25a48fb89e Allow Unicode chars to be dumped by yaml stdout callback (#40188)
* Allow Unicode chars to be dumped by yaml stdout callback

Allow Unicode in yaml.dumper to support printing strings unescaped with
\uxxx chars.

Cf. https://stackoverflow.com/a/29600111

* Switch from decode('utf-8') to the more compatible to_text()
2018-05-15 15:23:13 -07:00
Colin Nolan
3dd33e7417 Corrects environment variable in example. (#40162) 2018-05-15 17:22:07 -05:00
Kevin Breit
cd89bc5941 New module - meraki_network (#39782)
* New module for CRUD functionality of networks in a Meraki environment
- Relatively full integration test suite
- More functions to come

* Fix indent for PEP8.

- Look into why this didn't show on a local PEP8 test

* Dag requested changes.
- Removed a section in get_net as its backend isn't implemented
- Documentation modifications
2018-05-15 22:42:09 +02:00
Kevin Breit
aa8aee538e Meraki: Improved integration testing and results (#39761)
* Improved integration testing and results
- Added get_org() function to return data for single org
- Added a lot of new integration tests
- Changed result now shows, still probably could be better

* Fix formatting errors for PEP8
2018-05-15 22:41:09 +02:00
Sloane Hertel
b8a93c12e2 [aws_s3] Fix uploading src option on the target machine to a bucket (#39023)
* Fix backward compatibility for uploading src option on the target machine to a bucket

* Allow the module to handle errors for nonexistent files
2018-05-15 15:36:48 -04:00
Ryan Brown
ede47910f8 Add better handling for errors causing integration test instability (#40184)
* Add better handling for errors causing integration test instability
2018-05-15 15:31:19 -04:00
Sean Cavanaugh
0dc73e7822 add SVI example for Cisco IOS/IOS-XE platform (#40021)
on networktocode slack there was a user that wanted an example of how to add a switch vlan interface.  This will work and was tested on a 3850 cisco ios switch
2018-05-15 14:07:23 -05:00
Michael Miko
a363406d27 New zabbix_group_facts module (#39654) 2018-05-15 20:05:27 +02:00
David Beck
07d6daf787 [Fix] Commented out Section due to no Quotes (#24258)
Variables are not being passed into ansible unless they are quoted since yaml will automatically interpret them as comments
2018-05-15 12:20:09 -04:00
Madhura-CSI
b85970b2b0 New Module: ec2_vpc_vpn_facts (#35983)
* New module: ec2_vpc_vpn_facts

* Add integration tests for ec2_vpc_vpn_facts and the IAM permissions

* Add retry to VPC removal

* Use unique name for VGW

* Always clean up after tests and add retries
2018-05-15 12:13:46 -04:00
Nathaniel Case
f04c876ecd
Nxos fixes (#40117)
* Alter nxos_nxapi tests to test the right thing

* Defend #40027
2018-05-15 11:55:47 -04:00
Peter Oliver
caddf863df pkg returns 4 for "nothing to do" (#23007)
* pkg returns 4 for "nothing to do"

We need to handle this because our own checking for whether there's anything to do returns false negatives in certain circumstances.

We need to rename the response `rc`, because that name is reserved by
Ansible to indicate a failure if it is non-zero.

Fixes ansible/ansible#22781 and ansible/ansible-modules-extras#932.

* Don't rename `rc` to to `pkg_rc`, and instead override the failure state.

* Drop mention of renamed variable in `pkg5` module.
2018-05-15 11:52:54 -04:00
Martin Krizek
def434b5c3
apt_repository: fix rendering default mode in docs (#40152) 2018-05-15 17:36:23 +02:00
Eric Thiel
67acffb5f2 Fixes to improve ios_system idempotency (#38303)
Added detection of additional formatting for domain_name, domain_search,
lookup_source, and lookup_enabled on some software versions. In each
case they failed to detect existing commands with a '-' in it.

Fix: #38301
2018-05-15 10:27:40 -04:00
Jaak Ristioja
248bc0a4e8 modules, cloudengine: Fixed typo: ansilbe -> ansible 2018-05-15 13:42:04 +02:00
Abhijeet Kasurde
553cf4cdfc rabbitmq_binding: Update documentation (#40062)
This fix updates rabbitmq_binding documentation

* change 'exchange' to 'binding'
* Some minor doc fixes

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2018-05-15 03:52:55 -04:00
Abhijeet Kasurde
453358af3b jenkins_job_facts: Add validate_certs argument (#40065)
This fix adds validate_certs argument in jenkins_job_facts module.

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2018-05-15 03:39:47 -04:00
Sumit Jaiswal
9c0825a4cf
Infoblox ipv6 support feature (#39668)
* Update nios.py

* Update nios.py

* Update nios.py

* nios lookup errors out when there are no results #37970  Open	

Indentation failure issue resolved

* Returning empty list instead of None

In case of no results, res will be returned as an empty list instead of None (implementing ganeshrn comment)

* infoblox ipv6 support changes

* infoblox ipv6 support changes

* for fixing pep8 errors

* moving ipaddr check to utils

* adding ipv6addr check

* increasing space to resolve pep8 error

* modified the playbook examples to valid ones

* Update nios_network.py
2018-05-15 08:24:48 +05:30
Greg Sheremeta
291c89382c fix typo in nmcli doc (#40116)
fix typo in nmcli doc, balence -> balance
2018-05-15 07:52:59 +05:30
Dag Wieers
3cdd5da247
xml: Fix validate-modules issue (#40121) 2018-05-15 02:29:48 +02:00
Jordan Borean
d6eb642e88
win_template: fix issue where dest was specified as a directory (#39887) 2018-05-15 09:59:51 +10:00
Jordan Borean
e0813d7d47
become win: better error messages and docs update (#39936)
* become win: better error messages and docs update

* Fix syntax error and added changelog fragment
2018-05-15 09:33:36 +10:00
Jordan Borean
44ab948e5d
create module tmpdir based on remote_tmp (#39833)
* create module tmpdir based on remote_tmp

* Source remote_tmp from controller if possible

* Fixed sanity test and not use lambda

* Added expansion of env vars to the remote tmp

* Fixed sanity issues

* Added note around shell remote_tmp option

* Changed fallback tmp dir to ~/.ansible/tmp to make shell defaults
2018-05-15 09:31:21 +10:00
Jon Dufresne
1d640182c6 Update all pypi.python.org URLs to pypi.org (#38988)
For details on the new PyPI, see the blog post:

https://pythoninsider.blogspot.ca/2018/04/new-pypi-launched-legacy-pypi-shutting.html
2018-05-14 17:41:47 -05:00
Zim Kalinowski
b20a88c39d fix problem with documentation and param definition difference (#40067)
* fix problem with documentation and param definition difference

* removed some E324 from ignore.txt

* fixed mistake

* remove one more E324

* removed function app

* fixing append tags

* leaving append tags for later
2018-05-15 07:01:08 +10:00
Toshio Kuratomi
38ab36a625 Revert "Configurable list of facts modules (#31783)" (#40022)
This reverts commit 95655fae5c.
2018-05-14 13:46:14 -07:00
Nikita Chepanov
9514a618b7 Add copy module support for filesystems without chmod (#40099)
* only relevant to remote_src=True
* separate file content copying from file stats copying
* raise exception on mode='preserve', ignore otherwise

Fixes: #19731
Signed-off-by: Nikita Chepanov <nchepanov@bloomberg.net>
2018-05-14 13:17:38 -07:00
Jake Jackson
7d221c4663 updating win_chocolatey.py docs examples (#40101)
<!--- Your description here -->
Edit to the notepadplusplus example. 

Removed `.install` as per chocolatey documentation, the package is just notepadplusplus. 

docs found here: https://chocolatey.org/packages/notepadplusplus
+label: docsite_pr
2018-05-15 05:55:23 +10:00
Ramki Subramanian
3955e528b1 ec2_ami_copy: add tag_equality option for idempotence using tags (#40088)
* Allow idempotent use of ec2_ami_copy

When `tag_equality` is set true, use tags to determine
if AMIs in different accounts are the same, and don't
copy the AMI twice if they are the same.

Use AnsibleAWSModule and make imports more consistent
with other modules

* Update version added

* More code review changes

* Review changes - Recommended way to start EC2 connection
2018-05-14 15:11:48 -04:00
suacide24
dbb4493f17 removed eth on port-channel (#40090) 2018-05-14 21:09:44 +02:00
Martin Krizek
6d984c7988 low_level_execute_command: add stderr_lines 2018-05-14 12:05:03 -04:00
Rémy Léone
afc196acf1 Add a User-Agent string to the API request (#38587) 2018-05-14 09:55:47 -05:00
Dag Wieers
19977e80f0 Get rid of obsolete SEQUENCETYPE-check (#40078)
And small cosmetic change to examples.
2018-05-14 10:22:15 -04:00
Felix Kaechele
a8bdcd19f0 firewalld: amend docs for python3 only hosts (#40048)
Signed-off-by: Felix Kaechele <felix@kaechele.ca>
2018-05-14 08:38:10 -05:00
Robin Roth
d6e711b1de Allow empty list of names in pip module (#38789)
pip 10 gives exit code 1 for empty argument lists (pip < 10 gave exit 0)
see also https://github.com/pypa/pip/pull/4210

To still allow playbooks to pass when giving empty lists, don't call
pip in that case, but show a warning.
2018-05-14 14:51:10 +02:00
Robin Roth
42953c40ce Pip: Make main method smaller (#38788) 2018-05-14 14:49:41 +02:00
Trishna Guha
5eb6e3c611
nxos module doc fragment for authorize,auth_pass (#40074)
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
2018-05-14 17:23:26 +05:30
Abhijeet Kasurde
f484c1e8af
Remove redundant import from netapp module_utils (#39495)
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2018-05-14 16:18:07 +05:30
Abhijeet Kasurde
e53d9b0017
icinga2_feature: fix module in check_mode (#39853)
* icinga2_feature: fix module in check_mode

* modify check_mode logic

Fixes: #39830

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2018-05-14 16:14:42 +05:30
Abhijeet Kasurde
79c7d462c1
VMware: Check device type explicitly (#38729)
Check datatype of device instead of comparing them directly in
vmware_guest. Also, added testcases to check this behavior.

DPVG is not supported in current version vcsim

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2018-05-14 16:12:31 +05:30
Trishna Guha
5cf61d7401
ios cliconf plugin fix regex for version (#40066)
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
2018-05-14 12:40:04 +05:30
saichint
6fac574f17 fix nxos_ping issues (#40028) 2018-05-14 11:29:18 +05:30
Zim Kalinowski
5d2c23e2a3 fix for security group description crash (#38108) 2018-05-14 13:55:25 +08:00
Sietse Visser
d25420bbb9 Fix for Azure loadbalancer tags. (#39963)
* Fix for Azure loadbalancer tags.

It was possible to add tags to an Azure loadbalancer, but the tags were never set in Azure.
This patch fixes that.

* Pass shippable tests

* azure_rm_loadbalancer_facts requires rg

Getting facts of all loadbalancers via azure_rm_loadbalancer_facts requires a resource group.
This fix adds the rg as parameter to the list() call.

* Revert changes in azure_rm_loadbalancer_facts

The changes belong to another pull request.
2018-05-14 13:18:15 +08:00
Yuwei Zhou
c84e3e70ab location name (#40055) 2018-05-14 11:46:45 +08:00
Abhijeet Kasurde
57f6abdb84
VMware: new module: vmware_host_powerstate (#36577)
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2018-05-12 21:09:53 +05:30
markusbloch
a199c9b04f add state parameter to patch module (#33692)
* add state parameter to patch module

* add "version_added" to state parameter docu

* fix state parameter call

* change version_added to 2.6
2018-05-12 04:58:12 -04:00
Peter Farmer
16994bbdca cloudstack: use paging for listVirtualMachines (#40018)
Paging wasn't implemented, so once a cs domain has over 500 (default page size) VMs, Ansible can no longer find newly created VM.
2018-05-12 09:46:49 +02:00
Tim Rupp
06f76d6407
Removes ignores for f5 (#40038)
Removes ignores for f5 from unit tests and fixes any issues that
are being suppressed by the ignores
2018-05-11 17:12:17 -07:00
Tim Rupp
383a4f026e
Various f5 modules fixes (#40037)
* Add members to bigip_gtm_pool
* Add monitors to bigip_gtm_pool
* Add availability_requirements to bigip_gtm_pool
* Refactor bigip_gtm_pool
* Normalize the product value returned by gtm facts
* Corrected various documentation
* Updated various F5 coding conventions
* Add partition to bigip_static_route
* Added more unit tests
2018-05-11 14:07:28 -07:00
Tim Rupp
61e7c77dec
Various bigip gtm server and vs enhancements (#40033)
* Refactor bigip_gtm_virtual_server
* Add translation_address to bigip_gtm_virtual_server
* Add translation_port to bigip_gtm_virtual_server
* Add availability_requirements to bigip_gtm_virtual_server
* Add monitors to bigip_gtm_virtual_server
* Add virtual_server_dependencies to bigip_gtm_virtual_server
* Add link to bigip_gtm_virtual_server
* Add limits to bigip_gtm_virtual_server
* Add partition to bigip_gtm_virtual_server
* Fix bigip_gtm_server to correctly create other server types
2018-05-11 13:38:04 -07:00
Tim Rupp
1aa248f4e2
Adds various features to bigip virtual server (#40031)
* Add type to virtual_server
* Add address_translation to virtual_server
* Add port_translation to virtual_server
* Add ip_protocol to virtual_server
* Add firewall_enforced_policy to virtual_server
* Add firewall_staged_policy to virtual_server
* Add security_log_profiles to virtual_server
2018-05-11 13:09:59 -07:00
Tim Rupp
d312c2aed7
Various bigiq fixes (#40024)
Udpdating coding conventions
2018-05-11 12:59:29 -07:00
Tim Rupp
ea77c0d4f5
Adds the bigiq regkey license assignment module (#40025)
This module can be used to assign licenses to a bigip from a bigiq
regkey pool
2018-05-11 12:12:59 -07:00
Tim Rupp
00a6b19e58
Fixes and additions for f5 modules (#39986)
Small fixes in the f5 module utils. I believe the action plugins now
work consistently across types of connections
2018-05-11 11:45:42 -07:00
Brian Coca
8654508cbd
added check mode spport to package_facts (#39801)
* added check mode spport to package_facts

fixes #39789

* also service_facts
2018-05-11 14:04:08 -04:00
Brian Coca
95655fae5c
Configurable list of facts modules (#31783)
* configurable list of facts modules

 - allow for args dict for specific modules
 - add way to pass parameters
 - avoid facts poluting test
 - move to 'facts gathered' flag
 - add 'gathering' setting tests
2018-05-11 13:59:54 -04:00
Alex Stephen
7c510a2549 New Module: GCP Compute Instance Templates (#38907) 2018-05-11 10:50:32 -07:00
Martin Krizek
dccb0d035b
vault: check dir existence before creating a file (#40010) 2018-05-11 19:29:44 +02:00
lu1as
21004d86f9 "route" has to be the first option in ufw command (#31756)
For supporting deletion of ufw routes, route option has to be placed before delete option
2018-05-11 16:21:27 +01:00
Tim Rupp
48e5791860
Minor fixes and additions to f5 modules (#39987)
* Fixes to docs
* Fix escaping quotes in bigip_command
* F5 coding conventions cleanup
* “warn” and “chdir” parameters added to bigip_command
2018-05-11 07:55:48 -07:00
znantho
fff7915faa [aws][doc] Update documentation for wait_timeout option (#39875)
Based on the documentation, 'wait_timeout' is 'Used in conjunction with instance_ids option'.  This lead me to believe that I could not use this parameter to try and solve the 'Waited too long for ELB instances to be healthy' error I was experiencing.
2018-05-11 07:44:46 -07:00
Toshio Kuratomi
03194880c1 Set prev_state in the state functions
This seems a little like duplicating code since all of the called
functions need it but prev_state isn't part of argument parsing so it
doesn't belong in the toplevel main() function.
2018-05-11 06:35:03 -07:00
Toshio Kuratomi
9be31fc79b Don't pass b_path into state functions; those transform to byte strings on their own
It feels like this repeats itself because it pulls the creation of
a byte string for path into every state function.  However, it actually
cleans the API by only passing a single parameter for a thing (the path)
instead of sending it in twice.
2018-05-11 06:35:03 -07:00
Toshio Kuratomi
e17ee368e3 Improve comments about file_commmon_arguments 2018-05-11 06:35:03 -07:00
Toshio Kuratomi
160f2ace51 Switch from calling exit_json() to returning results
Well organized programs should only have a few successful exit points.

This commit moves all of the successful exit points for the file module
into the main() function.  Other functions return their results to the
main function which can then choose whether there is more procesing to
do before exit or not.
2018-05-11 06:35:03 -07:00
Toshio Kuratomi
cac11f9b80 Port away from fail_json()
Use an exception to return failures rather than fail_json().  This way
we can easily catch the failures if the calling code decides it can deal
with it.  This has the side effect of making it easier to unittest this
code as we can catch the expected exceptions instead of having to catch
the interpreter exiting and then parse stdout for the expected data.
2018-05-11 06:35:03 -07:00
Brian Coca
fc57f7bd5f fix comma 2018-05-11 09:18:31 -04:00
Ed Schaller
5ac41ee8d8 Fix interfaces_file to accept allow-* (#37847) 2018-05-11 13:47:06 +01:00
Felix Fontein
d14d4d8cab Improving documentation: make more general (less Let's Encrypt specific), and improve formatting. (#39979) 2018-05-11 03:45:11 -04:00
Martin Krizek
2db375e4aa
apt_key: clarify the keyring option in docs (#39950) 2018-05-11 07:45:20 +02:00
Martin Krizek
b2929f0eba
Fix callback._dump_results to dump vaulted data v2 (#39975) 2018-05-11 07:44:29 +02:00
Monty Taylor
fea71d2767 Update Jesse Keating's github id (#39904)
Jesse is no longer j2sol, he's now omgjlk.
2018-05-11 07:38:15 +02:00
Tim Rupp
c5fa718174
Adds bigip_device_license module (#39985)
This module can be used to license and unlicense BIGIP devices. This
does not include licensing them via BIGIQ. To do that, use BIGIQ modules
2018-05-10 21:44:59 -07:00
Zim Kalinowski
a8b4ce5c5d fixed data disk issue crash (#39716) 2018-05-11 11:44:34 +08:00
Toshio Kuratomi
4e2876be9f Initial refactor of the file module
* Separate the logic for each state into separate functions
* Start the process of separating out initialization (pre-processing of
  parameters that cannot be done via arg spec) from the logic to
  implement each state.
* Start the process of raising exceptions for errors and returning
  result values from each state implementing function   Goal is for all
  fail_json's to be consolidated into exception handlers at the toplevel
  and for there to be only one exit_json() at the toplevel.
2018-05-10 14:48:28 -07:00
Toshio Kuratomi
6b6c4914d2 Initial cleanup of file module
* Remove use of six.b as Python-2.6+ have byte literals.
* Make AnsibleModule a global object so we'll have access to it in all
  the functions we're going to break this up into.
* Rework the parameters so things that are in file_common_args are used
  from file_common_args or the reason for deviation is documented.
* Remove validate as a parameter: this should be taken care of by
  removing it from params before the copy and template action plugin
  invoke file.
* Rename diff_peek to _diff_peek as it is an internal parameter.
* add module_name execute_module call to assemble so that it is more greppable
2018-05-10 14:48:28 -07:00
Toshio Kuratomi
d994595660 Make the copy module pass correct parameters to file module 2018-05-10 14:48:28 -07:00
Toshio Kuratomi
b9a00372c2 Categorize FILE_COMMON_ARGS
Some file_common_args are not common to all file modules.  Divide the
args into categories for a future refator of this into a separate
file_argspec.
2018-05-10 14:48:28 -07:00
Tim Rupp
4d691e9d7b
Various fixes and features for bigip modules (#39972)
* Removed forwarders parameter that did not work
* Updated coding conventions
* Added ssl_cipher_suite and ssl_protocols to bigip_device_httpd
* Added more unit tests
2018-05-10 10:59:49 -07:00
Jacob McGill
67f387bc3b Update default for dscp to not allow APIC to handle it (#39970) 2018-05-10 19:57:20 +02:00
Tim Rupp
742fd3a91a
Adds misc fixes for gtm facts module (#39966)
Codifies some parameters and fixes f5 coding conventions
2018-05-10 09:57:27 -07:00
Tim Rupp
84136c0248
Adds the bigip gtm monitor bigip module (#39965)
This module can be used to manage bigip monitors on a bigip's GTM
2018-05-10 09:57:17 -07:00
Tim Rupp
08516df29d
Adds bigip gtm monitor firepass module (#39964)
This module can be used to manage firepass monitors on a bigip's GTM
2018-05-10 09:30:06 -07:00
Tim Rupp
115ba79f10
Adds the bigip gtm monitor https module (#39943)
This module is used to manage the HTTPS monitors on a GTM
2018-05-10 08:47:12 -07:00
Tim Rupp
4f703cf299
Adds module for F5 gtm tcp half open monitors (#39939)
This module can assist in managing TCP half open monitors in GTM
2018-05-10 08:46:53 -07:00
Tim Rupp
632a39232c
Adds the bigip gtm monitor tcp module (#39942)
This module can be used to manage tcp monitors on GTM
2018-05-10 08:46:23 -07:00
Rostyslav Davydenko
5f7c7becde aci_l3out: Add initial ACI l3Out implementation (#37570)
* Initial implementation of ansible ACI L3Out module

* Small documentation and parameter name fixes

* fix copy-paste error

* fix sanity for version_added = 2.6

* Removed deprecated options. Added PIM protocol support

* aci_l3out: add more examples and query option

* Handle DSCP option properly
2018-05-10 16:29:49 +02:00
Alex Stephen
7cfbf43f4b New Module: GCP Compute Instances (#38906) 2018-05-10 07:29:13 -07:00
Tim Rupp
868c2630dd
Adds bigip gtm monitor http module (#39944)
This module can be used to manage http monitors on a GTM
2018-05-10 06:26:13 -07:00
Martin Krizek
a1620ee2e0
git: clarify the archive option in docs (#39956) 2018-05-10 14:39:42 +02:00
Matthew Stone
e80ea39903 Adding slxos_l2_interface module (#39309) 2018-05-10 13:17:35 +01:00
Matthew Stone
fb457b4200 Adding slxos_linkagg module (#39190) 2018-05-10 13:06:57 +01:00
Ikrom
9254f67f3e Update firewalld.py (#39951)
Typo fixed

+label: docsite_pr
2018-05-10 12:13:53 +02:00
Trishna Guha
f1103a7a02
remove purge from nxos_logging doc, argspec (#39947)
* remove purge from nxos_logging doc, argspec

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

* shippable

Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
2018-05-10 15:28:37 +05:30
Matthew Stone
a8156c52d4 Adding slxos_interface module (#39123)
* Adding slxos_interface module

* Fixing sanity checks

* Fixing slxos_config tests for fixture change in slxos_interface
2018-05-10 10:09:42 +01:00
Ricardo Carrillo Cruz
56c5567912
Exit admin mode properly on iosxr_config (#39594)
Fixes #38811

When using 'admin' in iosxr-config, we need to pass an end
to config terminal session but also pass exit so we exit admin
mode.
2018-05-10 10:36:37 +02:00
Dag Wieers
d7f3d3b867
Fix module validation checks and remove old params (#39926)
This PR includes:
- Fixes to the majority of module validation issues
  (deliberate inconsistencies between docs and arg_spec)
- Removal of deprecated parameters 'method' and 'protocols'
- A few typos in the documentation

There are still some left-over validation errors, some are deliberate
(like doc strings as default to indicate ranges, etc.)
2018-05-10 08:47:08 +02:00
Tim Rupp
64ee8da3f1
Adds the bigip_gtm_pool_member module (#39937)
This module can be used to manage individual pool members on a bigip's
GTM installation
2018-05-09 19:13:52 -07:00
Kami Gerami
3d315244af urls: fix typo in examples section (#39777) (#39778) 2018-05-10 12:02:17 +10:00
Tim Rupp
ad5fdf5eb7
Fixes for bigip_gtm_wide_ip (#39931)
Added the irules parameter. Misc corrections of invalid parameter
names and internal behaviors.
2018-05-09 17:28:07 -07:00
Andrew Gaffney
1cf07028d4
Don't display host pattern warning for empty groups (fixes #35255) (#39927) 2018-05-09 14:13:48 -05:00
Brian Coca
cbb6a7f4e8
Enabled unsafe and vault in JSON (#38759)
* allow to load json marked as unsafe or vault

 * centralized json code/decode, add vault support
 * use generics to allow for more varied inputs
 * allow inventory to dump vault w/o decrypting
 * override simplejson also
 * add entry for unsafe also
 * load vaulted and unsafe json, support unvaulting if secrets provided
2018-05-09 14:01:51 -04:00
Andrew Gaffney
ff16e993be Fix task banner with 'actionable' callback when using templates in name (#38165)
This fixes #31074.
2018-05-09 13:57:28 -04:00
Anil Kumar Muraleedharan
3c32b483bc Fix for NameError (#39665)
Issue : NameError: global name ‘cnos_devicerules’ is not defined. while running cnos modules. 
Device Rule file validates the range and type of data going into each CLI based on device type it is executed against.
This has to be backported to 2.5
2018-05-09 17:09:25 +01:00
scottmishra
2b2bfc8032 Update panos_security_rule.py (#39036)
<!--- Your description here -->

+label: docsite_pr
2018-05-09 09:49:41 -05:00
Dave
5f0e6b2dc3 Update panos_op.py (#39013)
<!--- Your description here -->
The examples were apparently pasted from panos_object and the module name wasn't updated.
+label: docsite_pr
2018-05-09 09:47:42 -05:00
Kevin Breit
c36aa6ae50 Panos/doc fragment (#37696)
* Create PanOS module documentation fragment

- Module documentation fragment currently holds 3 parameters
- It most likely won't be used in every single module since there is
some variance

* Modified PanOS module for use doc_frags

- Where documentation is consistent, module documentation now uses a
documentation fragment instead of all documentation being contained in
the module.

* Formatting and syntax error fixes

Updated some formatting errors to make ansibot happy.

* Revisions for grammar
2018-05-09 09:13:22 -05:00
Chris Smolen
75304bd121 Update ios_system.py (#39623)
<!--- Your description here -->
Typo in the example of `domain_search`, was `domain-search`should be `domain_search`
+label: docsite_pr
2018-05-09 14:44:27 +01:00
Filippo Civiletti
c32aef74d5 expect: Fix typo in examples (#39900) 2018-05-09 13:55:17 +02:00
Abhijeet Kasurde
c164069079
VMware: new module : vmware_tag_facts (#39889)
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2018-05-09 13:38:26 +05:30
Martin Krizek
bf702e6d88
dnf: handle error when latest pkg not found (#39720)
* dnf: handle error when latest pkg not found

* Add integration test
2018-05-09 10:05:00 +02:00
Abhijeet Kasurde
3c389aee73 VMware: Add more robust logic to deal with VM moref (#39462)
This fix adds more robust logic to deal with virtual machine
managed object and its comparsion.

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2018-05-09 00:53:01 -04:00
Matt Martz
ea489b3f33
Update missed private doc for import_role (#39873) 2018-05-08 15:46:45 -05:00
Toshio Kuratomi
3e64036684 Fix encoding issue when parsing plugin examples
This caused a non-fatal traceback when building, for example, the module
documentation for the debug module.
2018-05-08 12:21:52 -07:00
Pilou
2397ca1a7e Fix unset ansible_virtualization_role (#39514)
Error was:
AttributeError("'str' object has no attribute 'startwith'",)

Closes #39138
2018-05-08 23:39:38 +05:30
Piotr Płazieński
0296c8466a Don't update cpu/memory allocation in configspec if there is no change. (#39790)
Fixes #38941
2018-05-08 21:54:50 +05:30
Nathaniel Case
c6270e15a6
Remove provider (and transport, where applicable) from consideration when not using connection=local (#39555)
* Remove provider (and transport, where applicable) from consideration

* Add tests that misplaced transport does not fail task
2018-05-08 12:06:37 -04:00
Matt Martz
384a0d8b01
Deprecate private for include_role (#39821) 2018-05-08 10:31:56 -05:00
Trishna Guha
f08332acb4
nxos enable mode (#39355)
* nxos enable mode

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

* fix prompt

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

* Add authorize,auth_pass

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

* remove byte string from exec_cli_command

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

* Add on_become test

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

* removed_in_version

Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
2018-05-08 15:31:02 +05:30
Felix Fontein
83df7249fd Renaming letsencrypt -> acme_certificate (#39816)
* Renaming letsencrypt -> acme_certificate.

* Also renaming in BOTMETA.yml.
2018-05-08 09:17:40 +02:00
saichint
e3bfbe5875 fix nxos_snmp_user issues (#39760)
* fix nxos_snmp_user issues

* shipppable fix
2018-05-08 11:57:12 +05:30
Markus Häll
58f9676d4b hashi_vault: fix for : in secret name (#39820) 2018-05-08 07:54:25 +02:00
Trishna Guha
3c35dd4f7f
nxos_linkagg normalize interface (#39591)
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
2018-05-08 11:15:05 +05:30
Deepak Agrawal
ef577b71cc
Handling of configurations blocks with end-* at the end of the block (#39673)
* handle end-policy issue

* revert changes in iosxr cliconf

* fix trailing parents not included in difference

* Moving fix to platform specific fix

* pep 8 issues
2018-05-08 10:02:50 +05:30
Ganesh Nalawade
09e3b5c92b
Fetch ios default config is defaults is enabled (#39741)
If default option is eanbled fetch the current
running configuration by adding `all` or `full`
flag
2018-05-08 09:38:08 +05:30
Arun Babu Neelicattu
eb430b2e57 azure: fix creation of TXT dns record sets (#38368)
As per `azure.mgmt.dns.models.txt_record.TxtRecord`, expected value for a
record is of type `[str]`. Fix TXT argspec to specify type as `list`
instead of `str`.

Fixes #37581

Reference: https://docs.microsoft.com/en-us/python/api/azure.mgmt.dns.models.txtrecord?view=azure-python
2018-05-07 22:32:39 -04:00
Jeffrey Forman
be3670f528 fix 'doas' become_method support, previously committed patch not submitted to devel branch (#37511)
* fix become_method 'doas' support by properly specifying becomecmd

a repatch of https://github.com/ansible/ansible/pull/13451/ which was never committed to 'devel' branch.

* fix play_context test for become_method doas to match new becomecmd
2018-05-07 21:30:47 -04:00
Stephan Lohse
1e4c389268 allow become methods for Jail connection plugin (#31746)
* allow become methods

- i personally tested 'su', 'sudo' and 'doas'

* forgot to import constants m(
2018-05-07 21:30:24 -04:00
Andrew Gaffney
01e8139d74 Update vars for loop_control on each loop iteration (fixes #38899) (#39818) 2018-05-07 15:51:46 -05:00
Matt Martz
72ebd1bf46
Add IncludeRole.get_name to provide better name for include_role. Fixes #36343 (#39807) 2018-05-07 15:27:09 -05:00
Charles
ea7883ef7e Broken link to MSDN (#39814)
Fix broken link to MSDN site for FileSystemRights enumeration

+label: docsite_pr
2018-05-07 20:16:23 +01:00
Toshio Kuratomi
75283983f6
Use a more exact regex (#39811)
The pattern we're matching can have zero or one p.  Be more careful to
match exactly that.

Slight revision of #39730
2018-05-07 11:12:42 -07:00
Matt Martz
5ec34f65d9
Pass obj=data to AnsibleParserError for context in IncludeRole. Fixes #31374 (#39805) 2018-05-07 11:25:28 -05:00
Matt Martz
1663b64e18
Allow subspec defaults to be processed when the parent argument is not supplied (#38967)
* Allow subspec defaults to be processed when the parent argument is not supplied

* Allow this to be configurable via apply_defaults on the parent

* Document attributes of arguments in argument_spec

* Switch manageiq_connection to use apply_defaults

* add choices to api_version in argument_spec
2018-05-07 11:23:13 -05:00
Abhijeet Kasurde
108eac9339 VMware: Allow user to add host without cluster (#39490)
This fix allows user to add ESXi host system under folder
without requiring to specify cluster name.

partially fixes: #38300

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2018-05-07 11:20:48 -04:00
Erwan Velu
2214c747a2 facts: Detecting NVME partitions under Linux (#39730)
In the current state of the code, the nvme partitions are returned as empty as in :
        "ansible_devices": {
            "nvme0n1": {
                "model": "SAMSUNG MZVLW256HEHP-000L7",
                "partitions": {},

The parsing of the /sys/block/<diskname> try to find a disk named like :
    <diskname><x> as in sda1 for sda

But in the nvme context, the partition of nvme0n1 is named nvme0n1p1.
This add a possible 'p' between the diskname and the partname.

This patch simply add the option of having a 'p' between the diskname
and the partname.

The patch works on my host :
                "model": "INTEL SSDPEDMD400G4",
                "partitions": {
                    "nvme0n1p1": {
                         ...
                        "size": "93.13 GB",
                    }

Fixes #38742
Signed-off-by: Erwan Velu <erwan@redhat.com>
2018-05-07 16:08:46 +01:00
Matt Martz
efff75389d
Use updated task, instead of original, non-merged included_file._task (#39762)
* Used updated task, instead of original, non-merged included_file._task. Fixes #39637

* Add changelog entry
2018-05-07 10:01:35 -05:00
Alex Stephen
1663539327 Adding support for GCP Compute Health Checks (#37438) 2018-05-07 07:57:25 -04:00
Abhijeet Kasurde
d70b3b4661
VMware: New module: vmware_tag (#37261)
This module is based on vSphere REST API. This module allows
user to manage various tags and their association with
categories. This fix also adds vCenter REST client library which can
be re-used for other REST based modules.

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2018-05-07 16:30:16 +05:30
Matthieu Fronton
a0b4462aea vmware_guest: cast vlan to int or str when relevant (#39726)
`network['vlan']` should be a VLAN ID
Integers passed around using jinja variable references are
converted to strings (see # 9362)
The # 32738 PR should allow using 'NativeType' in ansible
Explicitly converting to integer will make the module works
as expected with or without the NativeType support

`network['vlan']` can also be a VLAN NAME (fallback)
Explicitly converting to string will make the module works
as expected with or without the NativeType support
2018-05-07 15:50:34 +05:30
Abhijeet Kasurde
bc59dc471b VMware: New module: vmware_portgroup_facts (#36740)
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2018-05-07 05:06:33 -04:00
Abhijeet Kasurde
d839746123 VMware: report failure if no snapshot exists on VM (#38651)
This fix add correct reporting of failure if VM does not contain
any snapshots for following operations - rename, remove and revert.

Fixes: #37906

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2018-05-07 03:11:49 -04:00
Abhijeet Kasurde
1c8a7d06e5 VMware: new module : vmware_resource_pool_facts (#38674)
This module adds capability to provide facts about all resource
pools in given environment.

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2018-05-07 02:34:42 -04:00
Abhijeet Kasurde
0d29826e52 VMware: Refactor vmware_host_facts (#39273)
* Updated documentation
* Error handling in find_obj
* Updated return facts example

Fixes: #39265

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2018-05-07 02:34:14 -04:00
Abhijeet Kasurde
693065da1e VMware: new module : vmware_local_user_facts (#37167)
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2018-05-07 02:25:37 -04:00
Abhijeet Kasurde
02f1d263c7 VMware: new module: vmware_vswitch_facts (#37176)
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2018-05-07 02:25:31 -04:00
Sachidananda Urs
3324765fdd lvg: Allow unit to be specified for pesize (#39666) 2018-05-07 07:50:58 +02:00
Ganesh Nalawade
0ac222d68b
Fix nxos terminal plugin regex (#39659)
Fix nxos terminal plugin regex to match
command prompt without newline character as prefix
2018-05-07 09:06:00 +05:30
Abhijeet Kasurde
d1cd6ee56d VMware: Allow user to set customization specification (#38530)
This fix adds new argument parameter which allows user to
set customization specification which is already created with required
values like Windows Product Key and Networking details etc.

Fixes: #38404

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2018-05-06 19:51:16 -04:00
Abhijeet Kasurde
6e6325503a VMware: check SwitchUUID value before assigning (#38369)
This fix adds a check for switchuuid value of distributed virtual switch.
When there is no association between hostsystem and distributed virtual portgroup,
both specified by user, then module does not find DVSwitch.
This patch tries to mitigate that problem.

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2018-05-06 19:31:40 -04:00
Seuf
82645bdf40 Added alexanderzobnin-zabbix-datasource datasource type (#36948) 2018-05-05 15:03:44 -04:00
Daniel Jaouen
63ce4cf03d Homebrew: Update _uninstall_current_package to use the --force option (#33360) 2018-05-05 13:03:05 -04:00
hyperized
f210bbec50 rabbitmq_bindings rewrite (#35651)
* Attempt to get rid of globals

* Relocate imports and make formatting non-automatic

* spacing!
2018-05-05 10:26:47 -04:00
Shinichi TAMURA
75e69fe709 timezone module: fixed timezone identification logic in *BSD (#36715) 2018-05-05 10:26:38 -04:00
René Moser
aa874c3c36
influxdb_query: fix use of common return results (#39626) 2018-05-05 14:11:42 +02:00
Matt Martz
3b496db4d8
Make sure that the implicit async_status gets the env from a task with async. Fixes #39699 (#39764) 2018-05-04 18:43:33 -05:00
Jordan Borean
fc210a4584
base64 filter: Added ability to specify encoding (#39714)
* base64 filter: Added ability to specify encoding

* Added unicode chars for further testing

* Removed errors to keep previous behaviour in place

* Removed surrogate pairs due to issues loading YAML in CI
2018-05-05 09:16:58 +10:00
Rob
b5cffe8ced [aws] Create classes for Application Load Balancer (#33769)
* Create classes for Application Load Balancer
* Add unsupported CI alias
* Add AWSRetry
* Add integration tests using the ALB
2018-05-04 16:22:00 -04:00
Mickaël Guérin
8ac69b0a5f Fix gathering facts in run_once play (#39453)
* Fix gathering facts in run_once play

Fixes https://github.com/ansible/ansible/issues/39312

* Check that run_once doesn't prevent fact gathering
2018-05-04 15:33:32 -04:00
Alex Stephen
05d5d21d1c New module: GCP Container Node Pools (#37325) 2018-05-04 15:19:51 -04:00
Alex Stephen
5b0ce0222b Bug fixes for GCP Compute Address (#38630) 2018-05-04 14:41:55 -04:00
Alex Stephen
e177cf5831 New module: GCP Pubsub Topics (#38627) 2018-05-04 14:32:28 -04:00
Alex Stephen
e116c6cee8 New module: GCP Pubsub Subscriptions (#38626) 2018-05-04 14:31:34 -04:00
Alex Stephen
478759a686 New module: GCP Compute Subnetworks (#38621) 2018-05-04 14:29:38 -04:00
Alex Stephen
01f0e4ac6f New module: GCP Compute Networks (#38618) 2018-05-04 14:28:11 -04:00
Alex Stephen
768a81dd4b New module: GCP Compute Routes (#38619) 2018-05-04 14:27:29 -04:00
Martin Krizek
c57d476871
import_role docs: loop is not supported (#39725) 2018-05-04 19:36:33 +02:00
Ondra Machacek
39d9ff9d2c ovirt: Don't return ID as list in fetch_nested (#39736)
* ovirt: Don't return ID as list in fetch_nested

* ovirt_permissions_facts: Fix pylint
2018-05-04 11:40:17 -05:00
Matt Martz
3d5a7d6dc2
Allow using action/local_action on includes and imports (#37260)
* Prevent using action/local_action on includes and imports. Fixes #28822

* Use ModuleArgsParser to determine action instead of disallowing action/local_action with import/include

* Add to_native

* switch back to block in task_ds, use ModuleArgsParse otherwise

* var should be task_ds

* Add test validating action+include_tasks
2018-05-04 11:10:50 -05:00
Trishna Guha
dddcbb7198
use show run instead of section pipeline ios_l2_interface (#39658)
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
2018-05-04 21:22:09 +05:30
Matt Martz
d44fd70d02
Fix E126, E123 pep8 errors, and ansible-format-automatic-specification pylint error (#39740) 2018-05-04 09:40:08 -05:00
Ondra Machacek
dda31aa3f7 ovirt: Return ID for permissions facts (#39721) 2018-05-04 04:03:34 -04:00
Trishna Guha
9eff1f1d74
Handle nxos_feature issue where json isn't supported (#39150)
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
2018-05-04 12:21:58 +05:30
Yuwei Zhou
9348809184 Fixes #37731 Create Internal Loadbalancers with azure_rm_loadbalancer, support SKU (#38077)
* create internal loadbalancer

* fix test

* remove duplicate test

* clean up

* fix doc

* lint

* add sku support

* update version

* change to the version the same as CLI

* add pip support sku

* fix lint

* fix test

* Update main.yml

* add changelog entry
2018-05-04 13:17:05 +08:00
Pilou
a5d320f8e7 vdirect modules: fix 'import' sanity test (#39706)
* vdirect modules: fix 'import' sanity test

* Remove passing file from import skip list.

* vdirect modules: fix validate-modules warnings

- Arguments with a default should not be marked as required
- add choices in doc

* vdirect_runnable: use formatting function
2018-05-03 18:13:06 -07:00
Toshio Kuratomi
6b159fdb03 Fix for file module with recursive permission setting and broken symlinks
There was a traceback when setting permissions on a directory tree when
there were broken symlinks inside of the tree and follow=true.  chmod -R
ignores broken symlinks inside of the tree so we've fixed the file
module to do the same.

Fixes #39456
2018-05-03 17:54:34 -07:00
Toshio Kuratomi
4f664f8ff6
Fix for file module with symlinks to nonexistent target (#39635)
* Fix for file module with symlinks to nonexistent target

When creating a symlink to a nonexistent target, creating the symlink
would work but subsequent runs of the task would fail because it was
trying to operate on the target instead of the symlink.

Fixes #39558
2018-05-03 17:50:43 -07:00
Jordan Borean
f75b7a9437
win_get_url: Fixed a few issues with using FTP and added tests (#39646)
* win_get_url: Fixed a few issues with using FTP and added tests

* Fixed typo in docs
2018-05-04 08:39:37 +10:00
Brian Coca
df1001577f
rebase base playbook base (#39533)
* rebase base playbook base

fixes issues with loop control allowing generic attributes it shouldn't
2018-05-03 18:29:47 -04:00
Kevin Breit
c8d287fece Meraki organization module (#38773)
* Initial commit

Query an organization within Meraki. No support is in place for managing
or creating yet

* Change output_level method and make the state parameter required.

* Implemented listing all organizations

- Updated documentation
- Parse results and return all organizations
- Parse results and return specified organization

* Framework for creating an organization

- Documentation example for organization creation
- Framework exists for creating organizations, pending PR 36809
- Created functions for HTTP calls
- Renamed from dashboard.meraki.com to api.meraki.com
- Added required_if for state

* Remove absent state

- Meraki API does not support deleting an organization so absent is removed
- Updated documentation to call it state instead of status

* Small change to documentation

* Support all parameters associated to organization

- Added all parameters needed for all organization actions.
- None of the added ones work at this time.
- Added documentation for clone.

* Integration test for meraki_organization module

* Rename module to meraki for porting to module utility

* Meraki documentation fragment

- Created initial documentation fragment for Meraki modules

* Add meraki module utility to branch. Formerly was on a separate branch.

* CRU support for Meraki organization module

* CRU is supported for Meraki organizations
* There is no DELETE function for organizations in the API
* This code is very messy and needs cleanup
* Create and Update actions don't show status as updated, must fix

* Added Meraki module utility to module utility documentation list

* Added support for organization cloning
* Renamed use_ssl to use_https
* Removed define_method()
* Removed is_org()
* Added is_org_valid() which does all org sanity checks

* Fixes for ansibot
- Changed default of use_proxy from true to false
- Removed some commented out code
- Updated documentation

* Changes for ansibot
- Removed requirement for state parameter. I may readd this.
- Updated formatting

diff --git a/lib/ansible/module_utils/network/meraki/meraki.py b/lib/ansible/module_utils/network/meraki/meraki.py
index 3acd3d1038..395ac7c4b4 100644
--- a/lib/ansible/module_utils/network/meraki/meraki.py
+++ b/lib/ansible/module_utils/network/meraki/meraki.py
@@ -42,7 +42,7 @@ def meraki_argument_spec():
     return dict(auth_key=dict(type='str', no_log=True, fallback=(env_fallback, ['MERAKI_KEY'])),
                 host=dict(type='str', default='api.meraki.com'),
                 name=dict(type='str'),
-                state=dict(type='str', choices=['present', 'absent', 'query'], required=True),
+                state=dict(type='str', choices=['present', 'absent', 'query']),
                 use_proxy=dict(type='bool', default=False),
                 use_https=dict(type='bool', default=True),
                 validate_certs=dict(type='bool', default=True),
diff --git a/lib/ansible/modules/network/meraki/meraki_organization.py b/lib/ansible/modules/network/meraki/meraki_organization.py
index 923d969366..3789be91d6 100644
--- a/lib/ansible/modules/network/meraki/meraki_organization.py
+++ b/lib/ansible/modules/network/meraki/meraki_organization.py
@@ -20,11 +20,9 @@ short_description: Manage organizations in the Meraki cloud
 version_added: "2.6"
 description:
 - Allows for creation, management, and visibility into organizations within Meraki
-
 notes:
 - More information about the Meraki API can be found at U(https://dashboard.meraki.com/api_docs).
 - Some of the options are likely only used for developers within Meraki
-
 options:
     name:
         description:
@@ -32,21 +30,18 @@ options:
         - If C(clone) is specified, C(name) is the name of the new organization.
     state:
         description:
-        - Create or query organizations
-        choices: ['query', 'present']
+        - Create or modify an organization
+        choices: ['present', 'query']
     clone:
         description:
         - Organization to clone to a new organization.
-        type: string
     org_name:
         description:
         - Name of organization.
         - Used when C(name) should refer to another object.
-        type: string
     org_id:
         description:
         - ID of organization
-
 author:
     - Kevin Breit (@kbreit)
 extends_documentation_fragment: meraki
@@ -86,7 +81,6 @@ RETURN = '''
 response:
     description: Data returned from Meraki dashboard.
     type: dict
-    state: query
     returned: info
 '''

@@ -103,6 +97,7 @@ def main():
     argument_spec = meraki_argument_spec()
     argument_spec.update(clone=dict(type='str'),
+                         state=dict(type='str', choices=['present', 'query']),
                          )

@@ -125,11 +120,9 @@ def main():

     meraki.function = 'organizations'
     meraki.params['follow_redirects'] = 'all'
-    meraki.required_if=[
-                           ['state', 'present', ['name']],
-                           ['clone', ['name']],
-                           # ['vpn_PublicIP', ['name']],
-                       ]
+    meraki.required_if = [['state', 'present', ['name']],
+                          ['clone', ['name']],
+                          ]

     create_urls = {'organizations': '/organizations',
                    }
@@ -162,23 +155,16 @@ def main():

-
-    # method = None
-    # org_id = None
-
-
-    # meraki.fail_json(msg=meraki.is_org_valid(meraki.get_orgs(), org_name='AnsibleTestOrg'))
-
     if meraki.params['state'] == 'query':
-      if meraki.params['name'] is None:  # Query all organizations, no matter what
-        orgs = meraki.get_orgs()
-        meraki.result['organization'] = orgs
-      elif meraki.params['name'] is not None:  # Query by organization name
-        module.warn('All matching organizations will be returned, even if there are duplicate named organizations')
-        orgs = meraki.get_orgs()
-        for o in orgs:
-          if o['name'] == meraki.params['name']:
-            meraki.result['organization'] = o
+        if meraki.params['name'] is None:  # Query all organizations, no matter what
+            orgs = meraki.get_orgs()
+            meraki.result['organization'] = orgs
+        elif meraki.params['name'] is not None:  # Query by organization name
+            module.warn('All matching organizations will be returned, even if there are duplicate named organizations')
+            orgs = meraki.get_orgs()
+            for o in orgs:
+                if o['name'] == meraki.params['name']:
+                    meraki.result['organization'] = o
     elif meraki.params['state'] == 'present':
         if meraki.params['clone'] is not None:  # Cloning
             payload = {'name': meraki.params['name']}
@@ -193,7 +179,10 @@ def main():
             payload = {'name': meraki.params['name'],
                        'id': meraki.params['org_id'],
                        }
-            meraki.result['response'] = json.loads(meraki.request(meraki.construct_path('update', org_id=meraki.params['org_id']), payload=json.dumps(payload), method='PUT'))
+            meraki.result['response'] = json.loads(meraki.request(meraki.construct_path('update',
+                                                                                        org_id=meraki.params['org_id']),
+                                                                  payload=json.dumps(payload),
+                                                                  method='PUT'))

diff --git a/lib/ansible/utils/module_docs_fragments/meraki.py b/lib/ansible/utils/module_docs_fragments/meraki.py
index e268d02e68..3569d83b99 100644
--- a/lib/ansible/utils/module_docs_fragments/meraki.py
+++ b/lib/ansible/utils/module_docs_fragments/meraki.py
@@ -35,6 +35,7 @@ options:
         description:
         - Set amount of debug output during module execution
         choices: ['normal', 'debug']
+        default: 'normal'
     timeout:
         description:
         - Time to timeout for HTTP requests.
diff --git a/test/integration/targets/meraki_organization/aliases b/test/integration/targets/meraki_organization/aliases
new file mode 100644
index 0000000000..ad7ccf7ada
--- /dev/null
+++ b/test/integration/targets/meraki_organization/aliases
@@ -0,0 +1 @@
+unsupported

* Formatting fix

* Minor updates due to testing
- Made state required again
- Improved formatting for happier PEP8
- request() now sets instance method

* Fix reporting of the result

* Enhance idempotency checks
- Remove merging functionality as the proposed should be used
- Do check and reverse check to look for differences

* Rewrote and added additional integration tests. This isn't done.

* Updated is_update_required method:
- Original and proposed data is passed to method
- Added ignored_keys list so it can be skipped if needed

* Changes per comments from dag
- Optionally assign function on class instantiation
- URLs now have {} for substitution method
- Move auth_key check to module utility
- Remove is_new and get_existing
- Minor changes to documentation

* Enhancements for future modules and organization
- Rewrote construct_path method for simplicity
- Increased support for network functionality to be committed

* Changes based on Dag feedback and to debug problems

* Minor fixes for validitation testing

* Small changes for dag and Ansibot
- Changed how auth_key is processed
- Removed some commented lines
- Updated documentation fragment, but that may get reverted

* Remove blank line and comment

* Improvements for testing and code simplification
- Added network integration tests
- Modified error handling in request()
	- More testing to come on this
- Rewrote construct_path again. Very simple now.

* Remove trailing whitespace

* Small changes based on dag's response

* Removed certain sections from exit_json and fail_json as they're old
2018-05-04 00:01:05 +02:00
Julien Vey
a6d5656dd8 ec2_instance: add a retry to run_instance to help with ec2 consistency 2018-05-03 15:46:15 -04:00
Julien PRIGENT
1905a6e8fb ec2_vpc_route_table: Update matching_count parsing on find_subnets fu… (#38707)
* ec2_vpc_route_table: Update matching_count parsing on find_subnets function and tests

* ec2_vpc_route_table: Update matching_count parsing on find_subnets function
2018-05-03 15:05:24 -04:00
Sloane Hertel
923f676836
[ec2_vpc_vgw] [ec2_vpc_vpn] stabilize modules for PR 35983 (#38666)
* Stabilize ec2_vpc_vgw and ec2_vpc_vpn so tests for ec2_vpc_vpn_facts in PR 35983 can be run in CI

* Add updated placebo recordings

* ensure find_vgw uses the virtual gateway id if available

Add AWSRetry.jittered_backoff to attach_vpn_gateway to deal with errors when attaching a new VPC directly after detaching

Add integrations tests for ec2_vpc_vgw

* Sort VPN Gateways by ID
2018-05-03 14:19:19 -04:00
saichint
f99bae1776 Fix for nxos_snmp_host issues (#39642)
* fix snmp_host issues

* source files

* fix shippable

* remove defaults to match arg spec
2018-05-03 21:36:33 +05:30
saichint
99748cbfa4 fix nxos_snmp_traps issues (#39444)
* fix snmp_traps code

* add IT cases

* fix shippable

* fix shippable without ignore
2018-05-03 21:34:25 +05:30
Adam Miller
d49a09d05e
fix sanity checks to make shippable happy (#39685)
Signed-off-by: Adam Miller <admiller@redhat.com>
2018-05-03 10:36:08 -05:00
Seuf
cc477ba8cc Don't split line when no version available for plugin (#37907)
* Don't split line when no version available for plugin

* Fixed author github account
2018-05-03 11:10:18 -04:00
Mário Santos
947aa52327 Add new OpenStack module for managing cinder volume snapshots (#19122)
* Add os_volume_snapshot Ansible Module

* Add missing RETURN documentation

* Fix YAML syntax

* Add ANSIBLE_METADATA

Signed-off-by: Mário Santos <mario.rf.santos@gmail.com>

* Bump the ansible version

Signed-off-by: Mário Santos <mario.rf.santos@gmail.com>

* Add support for check_mode

Signed-off-by: Mário Santos <mario.rf.santos@gmail.com>

* Fix sanity tests

Signed-off-by: Mário Santos <mario.rf.santos@gmail.com>
2018-05-03 09:15:39 -05:00
Sloane Hertel
151f9d2ebf [cloud] aws_direct_connect_connection: improve return docs (#37677)
Fixes #29381

Fix uses of AWSRetry

Fix exception handling

Update module to use AnsibleAWSModule
2018-05-03 08:45:38 -04:00
Will Thames
29770a297a Fail with nice error message if elb target_type=ip not supported (#38313)
* Add helpful failure message if target_type=ip is not supported

Create test case for target_type=ip not supported

* Update elb_target_group module to latest standards

Use AnsibleAWSModule
Improve exception handling
Improve connection handling
2018-05-03 08:36:52 -04:00
wang shuang
918b29f0fc [doc] fix a typo in ec2_eni docs (#36571) 2018-05-03 08:36:30 -04:00
Will Thames
b5488b4e45 Change aws_acm_facts name parameter to be domain_name (#36986)
Match AWS's naming for domain name, but provide backward
compatible alias.
2018-05-03 08:35:55 -04:00
Felix Fontein
cb4db82354 Route53 check mode (#37273)
* Adding check mode for route53.

* flake8
2018-05-03 08:29:57 -04:00
Vinay Dandekar
ada2ea4387 Fix ec2_metadata_facts documentation (#37546)
- ec2_metadata_facts does not extend `url`
- Remove url_argument_spec for ec2_metadata_facts
2018-05-03 08:29:14 -04:00
cahlchang
e2908ae8df [aws] Add aws_iam_role check mode support (#39002)
* Check mode when adding

* Check mode when deleting

* Add check mode
2018-05-03 08:00:36 -04:00
Sloane Hertel
910bc892c6 ec2_ami: Properly delete snapshots (#39606) 2018-05-03 07:48:29 -04:00
Ganesh Nalawade
afdc2364f2
Fix eos_vlan associated interface check (#39661)
* Fix eos_vlan associated interface check

Fix eos_vlan associated interface check by comparing
the interface in want and have without converting the
interface name to lower

* Update eos_vlan docs
2018-05-03 17:07:30 +05:30
Loïc Blot
88df583af7 New module: AWS storage gateway facts (#39491)
* Add a module to get storage gateway facts

* Review fixes

* Last review fixes

* Add filtering gathering & some fixes

* doc fix

* API error handling

* Remove ec2_argument_spec import

Use imported BotoCoreError and ClientError rather than botocore.exceptions
2018-05-03 07:10:05 -04:00
aaronk1
ca36e07be0 update win_psmodule.py (#39631)
<!--- Fix minor typo in Powershell version requirement -->

+label: docsite_pr
2018-05-03 14:51:00 +10:00
vab2048
8d84039aa8 [ec2_vpc_route_table] Use 'network_interface_id' rather than 'interface_id' (#38499)
Updated documentation to refer to 'network_interface_id' rather than 'interface_id' as the latter results in an error: 'Parameter validation failed: Unknown parameter in input: \"InterfaceId\"'
2018-05-02 22:28:08 -04:00
Alex Stephen
b6aa132033 New module: GCP Compute Backend Services (#38611) 2018-05-02 16:59:27 -04:00
Alex Stephen
394abba1b9 New module: GCP Compute Backend Buckets (#38610) 2018-05-02 14:57:00 -04:00
Ryan S. Brown
9a607283aa Terraform module: pass plan_file argument correctly
Per #39611 the `terraform` module wasn't properly building plan-only
files.
2018-05-02 13:45:24 -04:00
Abhijit Menon-Sen
0a119c391a Only expand '~' based on become_user/remote_user
Change brought forward from #00c023e in stable-2.5.

Closes #39281 (bug report)
Closes #39540 (PR with substantially the same change)
2018-05-02 22:50:41 +05:30
Brian Coca
70d89b5487 use actual ssh executable as it might not be ssh 2018-05-02 12:10:25 -04:00
wznoinsk
f2db9d59c7 Update set_stats.py
<!--- Your description here -->

+label: docsite_pr
2018-05-02 11:10:52 -04:00
Ganesh Nalawade
eb5e15e7e0
Fix fetching ios default running config (#39475)
If default option is enable in that case only
add 'all' or 'full' flag
2018-05-02 19:27:56 +05:30
Michele Zuccala
9577cef3ba [cloud] route53_zone: create public zones associated to a reusable delegation set (#39502)
* Add option to specify reusable delegation set while creating public zones

* Add mutual exclusion argument spec for delegation set and VPC/private zone

* Get zone delegation set ID when updating a public zone
2018-05-02 09:25:15 -04:00
Ondra Machacek
17928ff666 ovirt_vms: Fix the module to work with check mode (#37916)
Fixes: https://github.com/ansible/ansible/issues/36712
2018-05-02 08:47:30 -04:00
Sharon Gratch
8bfc92fb27 Add Numa support. (#35838) 2018-05-02 03:52:16 -04:00
Yanis Guenane
dc420fc5fa Allow non-inclusion of setup task in junit report
The JUnit callback pushes every tasks in the report. Even the setup
tasks that - sometime - might clutter the report rather than being
useful, based on one needs.

This PR allows one to specify whether or not the setup tasks should be
part of the final report, defaulting to True to be backward compatible
to what is already in place today.
2018-05-02 00:00:36 -07:00
Adam Miller
69affddc7f
Add firewalld Rich Rule port forwarding example (#39534)
Example provided by Mike Cardwell (@mikehardenize) in an issue
comment 28349#issuecomment-385354551

Signed-off-by: Adam Miller <admiller@redhat.com>
2018-05-01 16:33:34 -05:00
Jordan Borean
04ae0c3312
winrm: removed old exec_command that is no longer used (#39572) 2018-05-02 07:04:53 +10:00
Dennis Conrad
77f5a8f422 Add AWS Inspector Target Module (#37464)
* Add AWS Inspector Target Module

* "ansible-test sanity" Fixes

* * Rename module
* Add integration test
* Incorporate feedback from s-hertel
2018-05-01 16:04:03 -04:00
Ondra Machacek
88b3b14a9c ovirt: fix quota_id check (#39568) 2018-05-01 14:26:34 -05:00
Eike Frost
6b554deb28 keycloak_client: add aliases for module options (matching API) (#39507)
* add aliases for module options which match API endpoint

* directAccessGrantsEnabled fixed in docs
2018-05-01 14:10:41 -05:00
Eric O'Callaghan
c11248c456 Update redhat_subscription.py (#39512)
fixed small typo of depracated to deprecated in redhat_subscription doc

+label: docsite_pr
2018-05-01 14:09:13 -05:00
Matt Martz
65049b6c42
Set default=no in import_role and include_role for private. Fixes #21077 (#39566) 2018-05-01 12:19:04 -05:00
Matt Martz
6acdc36317
Ensure we don't overwrite handlers from include_role when loading a play. Fixes #18140 (#39563) 2018-05-01 12:18:36 -05:00
Sam Doran
5a6bdef76b Only change expiration date if it is different (#38885)
* Only change expiration date if it is different

Modify user_info() method to also return the password expiration.
Compare current and desired expiration times and only change if they are different.

* Improve formatting on user tests

* Add integration test for expiration

* Add changelog fragment

* Improve integration test

Skip macOS and use getent module for validating expiration date.

* Fix expiration change for FreeBSD

* Don't use datetime since the total_seconds method isn't available on CentOS 6

* Use better name for expiration index field

Use separate tasks for verifying expiration date on BSD

* Use calendar.timegm() rather than time.mktime()

calendar.timegm() is the inverse of time.gmtime() and returns a timestamp in UTC not localtime
Add tests that change the system timezone away from UTC

* Mark tests as destructive and use test for change status

* Fix account expiration for FreeBSD

Use DATE_FORMAT when setting expiration date on FreeBSD. Previously the argument passed to -e was an integer of days since epoch when the account will expire which was inserted directly into master.passwd. This value is interpreted as seconds since epoch by the system, meaning the account expiration was actually set to a few hours past epoch.

Greatly simply comparing desired  and current expiration time by using the first three values of the struct_time tuple rather than doing a whole bunch of manipulations of the seconds since epoch.
2018-05-01 11:19:01 -04:00
Brian Coca
b9f7f582d1
remove properties from vars in include_role (#38968)
* remove properties from vars in include_role
* also from_ args
2018-05-01 10:16:59 -04:00
Dag Wieers
e9270fb100 mail callback: Exception info less important
So it seems on failure the last raised (but handled) exception is being
added to the task failure result, which makes it often unrelated to the
actual failure.

Since we assumed the exception was always related, using the exception
information for the subject is plain wrong (and let me to debug
completely unrelated ghost issues).

Also the exception details are now moved back in the output. Maybe we
should not show it unless there's no other information ? But at least it
should not be the mail's subject.
2018-04-30 21:45:10 -04:00
Toshio Kuratomi
81b2529159 Fix when template paths contain non-ascii chars and using the path in ansible_managed
Fixes #27262
2018-04-30 16:47:27 -07:00
Matt Martz
cca96b8c9d
Pass vars from import_playbook in early (#39521)
* Pass vars from import_playbook in early, as they may be needed to parse the imported plays. Fixes #33693

* Add test for import_playbook vars
2018-04-30 16:13:43 -05:00
Ryan Brown
269d682f70 Move camel2snake and snake2camel to common/dict_transformations.py (#39498)
Since it will be used outside just AWS modules, this commit moves
`camel_dict_to_snake_dict` and `snake_dict_to_camel_dict` functions into
a new module_utils file under common/ to match their wider usage.
2018-05-01 06:50:32 +10:00
David Davis
2d21c7da17 Allow the galaxy client to fetch from a url in role version data (#39396)
Currently if the ansible-galaxy client fetches a role from a galaxy
server, it then fetches the role from Github. This change allows a
galaxy server to provide an alternate source url that points to an
archive that contains the role version.
2018-04-30 15:47:43 -05:00
Matt Martz
c0043444c9
Remove unneeded imports in load_list_of_blocks (#39523) 2018-04-30 15:39:10 -05:00