Commit graph

21977 commits

Author SHA1 Message Date
Clement Trebuchet
c7981c4cc8 Add the NIOS RECORD PTR Module (#41900)
* Add the NIOS RECORD PTR Module

* FIX E241,E231, E105

* FIX module should not be executable

* FIX module RWX

* Remove change in nios_srv_record

* Remove change in nios_srv_record

* FIX test_nios_ptr_record_update_comment

* ADD: Integration and target tests for the NIOS PTR RECORD module.

* FIX module name in integrations tests

* Update integration

* Refactor nios_ptr_record module

* Refactor the nios_ptr_record_idempotence

* FIX name

* Smoketests for the NIOS modules does not take care of the PTR:RECORD object

* REM the default for view

* Add finals test, after adding the PR (https://github.com/ansible/nios-test-container/pull/1) in order to handle PTR:RECORD

* add the define nios specific constant for PTR:RECORD

* fix: documentation style

* add create an ipv6 ptr record

* rename class name, add ipv6 unittest
2018-07-11 23:55:28 +05:30
Fran Fitzpatrick
5928ec04ca Adds an ipmath filter (#41985) 2018-07-11 10:52:31 -07:00
Sloane Hertel
7086863c52 [s3_bucket] import urlparse (#42474) 2018-07-11 12:40:45 -04:00
Toshio Kuratomi
ccbac66128 Revert "Make ansible doesn't parse template-like password in user's input (#42275)"
This reverts commit de40ac02a5.

Passwords from the cli need to remain bytes on input otherwise we have
encoding problems when users input non-utf8
2018-07-11 09:30:42 -07:00
Jerry Chong
42f44b24c6 Fix NameError in pause module (#42038)
* Fix NameError in pause module

* Add comment and changelog

Co-authored-by: Jerry Chong <jchong@netbase.com>
2018-07-11 11:49:32 -04:00
Grzegorz Śliwiński
d6f20952fe Fix ec2_asg metric* option's version introduction - refs #25168 (#42626)
Introduced in 404f9260d9 during 2.6, so version_added: 2.5 was incorrect.
2018-07-11 10:57:11 -04:00
Nilashish Chakraborty
fa624eba29 Fixed regex to pick correct items (#42557) 2018-07-11 19:20:50 +05:30
Will Thames
42eaa00371 Provide kubernetes definition diffs in check_mode (#41471)
Move dict_merge from azure_rm_resource module to
module_utils.common.dict_transformations and add tests.

Use dict_merge to provide a fairly realistic, reliable
diff output when k8s-based modules are run in check_mode.

Rename unit tests so that they actually run and reflect
the module_utils they're based on.
2018-07-11 16:32:03 +10:00
hitsumabushi
cf7a42b4f4 allow empty line in src template file (#42493) 2018-07-11 11:29:07 +05:30
Jordan Borean
940d4a0e89
win_reboot: fix 2.6 issues and better handle post reboot reboot (#42330)
* win_reboot: fix 2.6 issues and better handle post reboot reboot

* changed winrm _reset to reset

* Add handler to reset calls when .reset() throws an AnsibleError on older hosts

* Moving back to _reset to get the issue fixed
2018-07-11 09:12:29 +10:00
Toshio Kuratomi
780c8986af Add boilerplate from __future__ and type declarations 2018-07-10 15:26:48 -07:00
Andreas Calminder
577e66660d Simple file locking feature (#42024)
* class for file locking feature
2018-07-10 14:13:27 -07:00
Marcos Alano
2d6bb2500e Add support for espeak-ng. Closes #42438 2018-07-10 15:53:00 -04:00
Andrew Gaffney
824524c67a
Display task banner before showing file diff (#42573) 2018-07-10 14:27:44 -05:00
Matt Martz
8aea8901c3 Add config to fail on invalid task attributes. Fixes #42479 2018-07-10 09:49:16 -04:00
Brian Coca
937e710485
ensure 'text' source assumptions (#42522)
* ensure 'text' source assumptions
2018-07-10 09:45:37 -04:00
Brian Coca
1c08eb8b27
fix irc module to work with py3 (#42267)
* fix irc module to work with py3

fixes #42256
2018-07-10 09:42:14 -04:00
Brian Coca
4a7940c562
Ensure string types (#42362)
* actually enforce string types

* unquote after its text

* fixed incorrect template type

* fixing string showed error in template typing
2018-07-10 09:41:33 -04:00
Kevin Breit
a65d9257fd Removed any temporary get_net() methods (#42391)
- Made appropriate changes where needed
2018-07-10 11:34:34 +02:00
Yuwei Zhou
e9bf3c70e6 disk fact should return create_option value (#42398) 2018-07-10 16:16:28 +08:00
Yanis Guenane
593f484d77 Fix E324 for vultr modules. (#42464) 2018-07-10 07:51:05 +02:00
Toshio Kuratomi
673c55f2ef Separate some 255 exit codes that are not ssh errors
The ssh connection plugin is overzealous in thinking that error code 255
can only come from ssh.  Python can return 255 in some circumstances and
error from php does as well.
2018-07-09 15:51:20 -07:00
Toshio Kuratomi
9350a81ae4 Port modules away from __file__
* __file__ won't work if we want to invoke modules via -m or if we
  figure out how to keep modules from hitting the disk with pipelining.
* module.tmpdir is the new way to place a file where it will be cleaned
  automatically.

Change format string to not depend on __file__:

* cloud/amazon/ec2_elb_lb.py
* cloud/amazon/elb_classic_lb.py

Use module.tempdir:

* packaging/os/apt.py
* files/unarchive.py
2018-07-09 15:51:20 -07:00
Pilou
72d7a1eb5c Setup module: use C() formatting function in parameter descriptions, add a task based example (#42411)
* setup module: use C() in parameters description

* setup module: use a task example
2018-07-09 15:08:01 -04:00
Matt Martz
abb05c98f3 Make sure we are comparing bytes extensions in inventory plugins (#42475)
* Ensure we are comparing text paths with extensions. Fixes #42118

* Add changelog
2018-07-09 12:24:51 -04:00
Brian Coca
8e1d223301
complete plugin docs (#42355)
* complete plugin docs

  * add missing 'plugin' option
  * user and password are now 'correctly' required
  * added  inventory source example and extension information for user
2018-07-09 11:50:50 -04:00
Brian Coca
2496fd35fb added required missing field for common yaml fmt 2018-07-09 11:43:21 -04:00
Matt Martz
50905b980d Support item label in v2_playbook_on_include (#42478)
* Support item label in v2_playbook_on_include. Fixes #42301

* test fixes
2018-07-09 11:27:00 -04:00
bpetit
9bd7bd5d46 [docs] Document requirements for plan_file option in terraform module (#42514)
plan_file is required if state: planned is used. This should be mentionned in the documentation.

+label: docsite_pr
2018-07-09 10:19:29 -04:00
Zhikang Zhang
70e33ef92c
Make ios_vlan identify vlans starting with 9 (#42247)
* Make ios_vlan identify vlans starting with 9

* Add unit test for vlan id start with 9
2018-07-09 09:50:06 -04:00
Jakub Libosvar
26b0908270 openvswitch_db: Make 'key' parameter optional (#42110)
The OVSDB schema consists of typed columns. The 'key' parameter is
required only for columns with type of a 'map'. This patch makes 'key'
an optional parameter to allow setting values for other column types
like int.

Fixes #42108
2018-07-09 19:12:41 +05:30
Fabian von Feilitzsch
e9c7b513a1 [k8s] allow user to pass list of resources in to definition parameter (#42377)
* allow user to pass list of resources in to definition parameter

* Add new validator for list|dict|string

* use string_types instead of string

* state/force information is lost after the first item in the list

* Add tests

* Appease ansibot
2018-07-09 08:33:16 -05:00
Paul Neumann
dfb2b3fdd5 ios_facts: Report space of file systems (#41850)
* ios_facts: Report file system space

Parse total and free space from dir output. For this, add a hash
filesystems_info containing the keys spacetotal_kb and spacefree_kb.

* ios_facts: Add unit test for file system space reporting

* ios_facts: Add integration test for file system space reporting
2018-07-09 09:15:31 -04:00
Felix Fontein
dbb58b34c3 Version must be quoted (otherwise it is printed as 2.1) (#42496) 2018-07-09 06:53:59 -04:00
Dag Wieers
3c35b1dbc5
sefcontext: Improve documentation (#42416)
* sefcontext: Improve documentation

* Clarify why this module does not apply changes to filesystems

* Fix

* More clarity
2018-07-09 12:13:25 +02:00
Dag Wieers
0fbaf9940f
cobbler_sync: New module to sync Cobbler changes (#39910)
This module is required if you're using Cobbler for provisioning
systems using Ansible.
2018-07-09 11:27:44 +02:00
Dag Wieers
198b62b906
file: Recover from unexpectedly disappearing files (#42281) 2018-07-09 11:27:25 +02:00
Dag Wieers
8eb1e8c0e6
Ensure boolean value 'yes' is shown and add types (#42361)
And a few small cosmetic changes.
2018-07-09 11:27:06 +02:00
Kevin Breit
7b07c9b220 meraki_network - Add support for disableMyMerakiCom (#42418)
* Add support for disable_my_meraki parameter

- Meraki added support for the disabling access to Meraki websites on
devices. This module now supports this.
- I haven't tested this as it was developed on an iPad. It will work
before submitting PR.
- Rework of payload generation code is required or at least
recommended.
- Integration tests need to be developed.

* Added support for disableMyMerakiCom parameter

* - Remove proposed functions as it isn't required for updates
- Add integration tests
- Still pending a case response from Meraki since I can't seem to
set disableMyMerakiCom to false after it's true

* Fixed word wrap problem

* Add version_added to disable_my_meraki
2018-07-09 11:21:34 +02:00
Kevin Breit
c644e3da79 meraki_network - Added proper response documentation (#42393)
* Added proper response documentation to meraki_network

* Missing colon
2018-07-09 11:21:12 +02:00
Kevin Breit
78fd5ce651 Improve documentation of module (#42332) 2018-07-09 11:19:19 +02:00
Kevin Breit
9cd2388d1a New module - meraki_ssid (#42329)
* Initial commit of meraki_ssid module
- CRUD functionality for Meraki wireless SSIDs
- Much more testing is needed
- Module is not currently idempotent

* Improve integration tests
- Original integration tests didn't have any assertions in it
- Single bug fix in module found via integration test

* Added idempotency support
- Changes are only made when needed.
- Added integration test to check for idempotency.
- Relies on a forthcoming PR to make idempotency check a single pass.

* Improved documentation
2018-07-09 11:18:12 +02:00
Kevin Breit
132943cac5 New module - meraki_mr_l3_firewall (#42328)
* Initial commit for meraki_mr_l3_firewall module

- CRUD functionality for layer 3 firewall rules on the Meraki MR access points
- Complimentary integration test
- Need to add support for SSID lookup

* Added support for specifying SSID name and improved documentation

* Added examples to documentation

* Removed whitespace
2018-07-09 11:17:14 +02:00
Kevin Breit
3d3d919c11 New module - meraki_mx_l3_firewall (#42326)
* Initial commig for meraki_mx_l3_firewall
- View and modify L3 firewalls applied to Meraki MX firewalls
- Initial integration tests included

* Added example documentation

* Added documentation for responses

* Documentation tweaks for typos

* PEP8 fix
2018-07-09 11:16:30 +02:00
Kevin Breit
ca5f9aab1e Meraki module utility - get_net() downloads networks if data isn't provided (#41423)
* Enable get_net() to download nets if data isn't provided

- Currently, get_net() requires data to be passed to it
- PR enables get_net() to download all networks if data isn't passed
- Slightly simpler code
- Best practice is to download nets early in execution

* Apply fixes related to get_net()

* Removed extra code from the rebase
2018-07-09 11:13:38 +02:00
Kevin Breit
eeada86554 Add net_id support to config_template (#42446)
- Added net_id support to config_template
- Changed integration test to use blocks to cleanup on failure
2018-07-09 11:11:16 +02:00
Kevin Breit
9036f846a3 meraki - Enabled support for configuration template configuration (#42392)
* Enabled support for configuration template configuration
- get_nets() now pulls down templates and networks
- A few changes in VLAN and network to operate as a POC

* Ansibot changes

- Fix undefined variable
- Document net_id in meraki_vlan

* Fix indentation
2018-07-09 11:10:27 +02:00
Kevin Breit
779f3c0c1a Allow module to claim devices into an organization (#42448)
- Before this, it allowed claiming devices into a network only
- Make integration tests a block
- Note, API doesn't allow unclaiming in an organization, only net
- Added an integration test for claiming into an org
	- Requires unclaiming manually
- There is a bug in the API which isn't showing claimed devices
2018-07-09 11:08:37 +02:00
Kevin Breit
5960b215bb meraki_admin - Added full return documentation for normal responses (#42487)
* Added full return documentation for normal responses

* Changed returned for responses

- Old responses were saying always returned, should have been success
or something more refined
2018-07-09 11:05:21 +02:00
Kevin Breit
0c59a3bc48 meraki_snmp - Added full response documentation for normal responses (#42488)
* Added full response documentation.

* Changed always to success for responses
2018-07-09 11:04:51 +02:00