Commit Graph

12172 Commits (97cc0cce7f53b704f8541530e42d5e515584cd95)

Author SHA1 Message Date
Clement Trebuchet 7c97bb5077 Devel ios vrf submode (#41659)
* add submode features ipv4/ipv6

* add tests for submode

* the parameters both_ * were not idempotent, in what is read in the configuration we have a list with 2 entries (import, export) while the input parameter has only one parameter which will be applied twice

* add docstring to the ios_vrf module + provide a fix for: https://github.com/ansible/ansible/issues/41581

* complete tests

* add missing description

* fix KeyError for address-family ipv*

* fix both_* tests

* fix E231, W292, W293

* fix W293

* remove set has it doesn't preserve order of routes

* fix E106

* remove ImportError: cannot import name OrderedDict

* We should be able to mix the parameters for the routes targets , while remaining imdepotent. During the first implementation we did not take this into account, which did not correspond to the reality of the needs in production (to be able to use each parameter indifemently together)

* remove epdb reference

* FIX E111, E106

* FIX E302

* using loop produce a result who  was not imdepotent

* FIX E241

* fix: used pass intead of list
6 years ago
Kevin Breit 2038ff5569 meraki_mx_l3_firewall - Fix idempotency for default rule logging (#42649)
* Fix idempotency and default syslog bugs

* Fix idempotency check for syslog_default_rule

* Syntax errors
6 years ago
Kevin Breit 9105149595 Cange URL for organization device lookup (#42648) 6 years ago
Peter Sprygada d086d57d11 adds a new feature to the telnet action plugin
This change adds a new argument to the telnet action plugin that will
cause the module to send a newline character before trying to login.
This is convienent when using telnet over a console connection that
needs an initial newline character to start the login process.

This change also will cause the sent command and command response to be
displayed on stdout when running in verbose mode (5 v's).
6 years ago
Henryk Konsek ebeb46aa61 Added Scaleway volume module (#41667)
* Added Scaleway volume module.

* Fixed imports order.

* Fixed version added.

* Improved sanity checks.

* Fixing style formatting.

* Added new line at the end of file. Fixed typo in comment.
6 years ago
Dag Wieers 5465dca7ec
aci_bd_subnet: Support parameter scope not set (#42675)
If parameter scope is not set (is None) the usual handling of lists does
not apply, and should be avoided or we get an exception.

This needs to be backported to earlier versions of Ansible.
6 years ago
Calvin Wu 7e42e88cc1 ecs_taskdefinition can absent without containers argument (#41398)
* ecs_taskdefinition can absent without containers argument

* add regression test for absent with arn

* Add PassRole privilege for ecs_cluster to pass
6 years ago
Ryan Brown e4c28571d0 Update to AnsibleAWSModule and remove now-duplicate fail_json_aws function (#42629) 6 years ago
Ganesh Nalawade 6a94090e7f
Fix junos facts integration test failures (#42623)
*  Make fetching old style facts optional
   and try to fetch the old style facts only when
   `ofacts` value is present in `gather_facts`
* Fix in junos_facts integration test
6 years ago
Matt Davis a5fc9a17f0
return wu result from inner job (#42647)
fixes #42423
6 years ago
Felix Fontein 765a5130d5 Docker modules: improve documentation on docker vs. docker-py Python package requirements (#42457)
* Make sure all docker-py/docker requirements are listed, and clarify about docker vs. docker-py.

* Adjusting changes made in #40839.
6 years ago
Dag Wieers 27f540ac5c
Add parameter types to documentation (#42572)
Few documentation fixes
6 years ago
rhorer 28820d3de0 Very slightly clean up the inline documentation 6 years ago
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
6 years ago
Sloane Hertel 7086863c52 [s3_bucket] import urlparse (#42474) 6 years ago
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.
6 years ago
Nilashish Chakraborty fa624eba29 Fixed regex to pick correct items (#42557) 6 years ago
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.
6 years ago
hitsumabushi cf7a42b4f4 allow empty line in src template file (#42493) 6 years ago
Marcos Alano 2d6bb2500e Add support for espeak-ng. Closes #42438 6 years ago
Brian Coca 1c08eb8b27
fix irc module to work with py3 (#42267)
* fix irc module to work with py3

fixes #42256
6 years ago
Kevin Breit a65d9257fd Removed any temporary get_net() methods (#42391)
- Made appropriate changes where needed
6 years ago
Yuwei Zhou e9bf3c70e6 disk fact should return create_option value (#42398) 6 years ago
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
6 years ago
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
6 years ago
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
6 years ago
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
6 years ago
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
6 years ago
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
6 years ago
Felix Fontein dbb58b34c3 Version must be quoted (otherwise it is printed as 2.1) (#42496) 6 years ago
Dag Wieers 3c35b1dbc5
sefcontext: Improve documentation (#42416)
* sefcontext: Improve documentation

* Clarify why this module does not apply changes to filesystems

* Fix

* More clarity
6 years ago
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.
6 years ago
Dag Wieers 198b62b906
file: Recover from unexpectedly disappearing files (#42281) 6 years ago
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
6 years ago
Kevin Breit c644e3da79 meraki_network - Added proper response documentation (#42393)
* Added proper response documentation to meraki_network

* Missing colon
6 years ago
Kevin Breit 78fd5ce651 Improve documentation of module (#42332) 6 years ago
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
6 years ago
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
6 years ago
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
6 years ago
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
6 years ago
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
6 years ago
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
6 years ago
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
6 years ago
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
6 years ago
Kevin Breit 0c59a3bc48 meraki_snmp - Added full response documentation for normal responses (#42488)
* Added full response documentation.

* Changed always to success for responses
6 years ago
René Moser d7c3d5501b
cs_vpc: fix disabled or wrong vpc offering taken (#42465) 6 years ago
Pilou 3301a0b530 docker_container: fix init check requirements (#40839)
* docker_container: ensure 'init' is supported

Check docker-py version too.

Move API version check in docker_container module since 'init' module
parameter isn't defined by other docker modules.

docker-py supports 'init' since 2.2.0:
https://github.com/docker/docker-py/blob/2.2.0/docs/change-log.md

* docker_container: fix compat with docker-py<2.2

Exception was:
TypeError: create_host_config() got an unexpected keyword argument 'init'
fatal: [localhost]: FAILED! => {
    "changed": false,
    "module_stderr": "Traceback (most recent call last):
                        File ansible_module_docker_container.py, line 2089, in <module>
                          main()
                        File ansible_module_docker_container.py, line 2084, in main
                          cm = ContainerManager(client)
                        File ansible_module_docker_container.py, line 1704, in __init__
                            self.present(state)
                        File ansible_module_docker_container.py, line 1724, in present
                            new_container = self.container_create(self.parameters.image, self.parameters.create_parameters)
                        File ansible_module_docker_container.py, line 826, in create_parameters
                            host_config=self._host_config(),
                        File ansible_module_docker_container.py, line 932, in _host_config
                            return self.client.create_host_config(**params)
                        File lib/python3.6/site-packages/docker/api/container.py, line 157, in create_host_config
                            return utils.create_host_config(*args, **kwargs)
                      TypeError: create_host_config() got an unexpected keyword argument 'init'",
    "module_stdout": "",
    "msg": "MODULE FAILURE",
    "rc": 1
}
6 years ago
Julien Vey 0f612d1b76 efs_facts: improve performance by reducing the number of api calls (#36520)
* efs_facts: improve performance by reducing the number of api calls

* Remove efs_facts tests from running in CI
6 years ago
René Moser 0e6628395a
cs_firewall: fix idempotence and tests for cloudstack v4.11 (#42458) 6 years ago
Jackson Isaac 39ec12f395 junos/junos_config.py: Add RVI Example (#41867) 6 years ago