Commit Graph

17817 Commits (40b7dffea8a2486be324f135cc615c7d00a06ffe)

Author SHA1 Message Date
Dag Wieers 967fbcb662 xml module: Add backup support (#28595)
This fixes #27949
7 years ago
Brian Coca 725d4d4bc8 added diff as new keyword (#28581)
added diff to fake options in ec2_vpc_nat_gateway test
7 years ago
Kira Rose 46cd8ba7cd Check Windows service status before nssm STOP (#28379)
* Check Windows service status before nssm STOP

Add a condition on calling nssm STOP inside Nssm-Remove, to check whether or not a service has already been stopped. Currently nssm throws an exception:

```
failed: [...] (item=...) => {"changed": false, "failed": true, "item": "...", "msg": "an exception occurred when invoking NSSM: serviceName: STOP: The service has not been started."}
failed: [...] (item=...) => {"changed": false, "failed": true, "item": "...", "msg": "an exception occurred when invoking NSSM: serviceName: The service has not been started."}
```

Behaviour after change:

```
ok: [...] => (item=...)
ok: [...] => (item=...)
```

* Added named parameter to new Get-Service cmdlet
7 years ago
Dag Wieers e7a525bd4a vmware_vswitch; Improve integration tests (#28484)
So the module was now not doing anything except adding a nic to a
vswitch. This PR adds idempotency checks, and removal checks.

We should probably add modification chacks as well, but I don't know
what the limitations are for vcsim.
7 years ago
Nathaniel Case ada7f248c0 Add 'Tested on' string to NX-OS modules (#28531) 7 years ago
Dag Wieers d830186e27 Fix the reboot_required return value (#28579)
As reported in #28565
7 years ago
Dag Wieers d8429a69c5 xml module: Parse and evaluate xpath on input (#28591)
* xml module: Parse and evaluate xpath on input

This fixes cmprescott/ansible-xml#68

* Update error string
7 years ago
Dag Wieers 26d75144b2 xml module: Implement diff mode (#28592)
This fixes #27952
7 years ago
Reid Wahl 3026e5eb15 Fixes #28584: modules/windows/win_get_url.ps1: Change -msg option to -message (#28585) 7 years ago
Ganesh Nalawade cd8c1c1108 Create persistent socket path using port and connection type (#28492)
* Create persistent socket path using port and connection type

*  Use remote address, port, connection type and remote user
   to create a socket path.

* Fix review comment
7 years ago
Matt 9407a17c40 Fix example
change count_tags to count_tag
7 years ago
Brian Coca 7b73ee0818 also strip strings to avoid spaces breaking match 7 years ago
Will Thames fbfa5624c3 [cloud] New module: aws_waf_facts module (#26671)
Initial implementation of waf_facts module

* Enhance waf_facts module to provide more info

Support check_mode trivially
Enhance rule and predicate information
Use AWSretry and wrap proper exception handling
Finish documentation
Remove arbitrary limits
Meet latest ansible standards.

* Rename module to use aws_ prefix.

Fix copyright.

Fix metadata version.
7 years ago
Patrick Murray b828b5d33b Fixing Issue #27270 - EFS TypeError (#27318)
* Fixing Issue #27270 regarding a TypeError invoked by the addition of a Filter type and List type.

* Fix SecurityGroup from always being reported as changed on PY3

On Python3, filter returns a generator.  This causes us to report that
security groups are always defined on Python3 even when there are none.

Also change filter() calls into list comprehensions.
7 years ago
Michael Tinning 282e743eb0 elb_application_lb: fix issue with boto parameter validation on Rules (#27333) 7 years ago
Trishna Guha cfc6d9f904 Tested against IOS XR version (#28563)
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
7 years ago
Stephen Jennings be2d4cc1c9 Check for an existing docker_network before trying to modify it (#24048)
This eliminates a TypeError in check mode.
7 years ago
Will Thames b1df75fc1c [cloud] Return AMI info on ec2_ami module when `changed=false` (#27867)
Fixes #27861
7 years ago
Sloane Hertel 24b49c2539 [cloud] New module: AWS Direct Connect connection (#26152)
* New module for AWS Direct Connect connections

Unittests for new module

Added utils that will be used by other Direct Connect modules

* pep8 fixes

* Correct aws_direct_connect_connection EXAMPLES to be valid yaml

* Make requested changes

* remove use of the variable changed

get rid of unnecessary parentheses

* Fix unit test

* Rename variable.

* Fix metadata version
7 years ago
David M. Lee 1d4ca0fd51 amazon: extract copies of boto_exception to module_utils.ec2 (#20403)
* amazon: extract boto_exception to ec2 module

This function was copy/pasted throughout several Amazon modules. This
causes a consistency problem, since some improvements to message
formatting were applied to some modules but not others. Now all modules
use the same, improved function.

* Rebase and make requested changes

* Rebase and make requested changes
7 years ago
mzizzi 587ab33415 [cloud] Add jittered backoff+retries to CloudFormation module (#27907) 7 years ago
Trishna Guha 4070a22c5b Tested against IOS version (#28559)
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
7 years ago
Trishna Guha 340f52ae96 tested against eos version (#28556)
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
7 years ago
Laurent Ribot f92ae0831b Fix : get proper snapshotVersion when no classifier (#27102) (#27103) 7 years ago
mikedlr f93515adb9 [MERGE] AWS module Guidelines - multiple changes to bring up to date and start on aws.core (#26871)
* aws module Guidelines - rewrite - add AWS WG - add fail_json_aws - more modern
practices and fix some spelling

* aws module Guidelines - minor further changes with agressive fill to 99 width

* aws module Guidelines - formatting fix as per gundalow request

* aws module Guidelines - mark more keywords and code with backquotes

* AWS module guidelines - fixes from ryansb review + minor other changes
7 years ago
Muhammad Panji 8ed0222eff fix sts_session_token parameter example (#28549) 7 years ago
Lukas Bednar 8c5b9d99ed ovirt_disks: added option to export disk to glance (#27959)
* ovirt_disks: added option to export disk to glance

* ovirt_disks: Moving exporting to separate branch

* ovirt_disks: removed redundant line obtaining disk obj
7 years ago
Yaniv Kaul 6b18a23385 [oVirt] Fix ovirt_disk.py example of adding a disk (#28496)
It was missing a required field - the storage_domain field.
7 years ago
Tareq Alayan abc5910d86 cloud/ovirt: set mac pools via ovirt_clusters (#28120)
MAC pools are set per cluster since ovirt 4.1. Before that it was set
per data center.
7 years ago
Nijin Ashok 3c1ee57155 [cloud] ovirt: Add VM lease option to the ovirt_vms module (#27710)
Ovirt 4.1 is having new feature of VM lease for high availability.
The commit add support for configuring this in ovirt_vms module.
7 years ago
maorlipchuk 07feec30d3 [oVirt] Update/Add functionalities for import storage domain (#26568)
* ovirt_templates: Update the argument spec of templates.

Add id of template since it is needed for register.

* ovirt_vms: Register unregistered VM.

Use register of VM with id instead of name since an
unregitered entity can be registered also without name attribute.

* ovirt_hosts: Add iscsidiscover to ovirt_hosts

Adding functionality of iscsidiscover to be used to discover iscsi
targets.

* ovirt_storage_domains: Add support for import block storage domain.

* Add functionality of partial import to unregistered VMs.

* Add functionality of partial import to unregistered Templates.

* ovirt_hosts: Add iscsilogin to ovirt hosts.

Add functionality of iscsi login to ovirt hosts to be used to connect to
iscsi targets and to be able to import iSCSI storage domain eventually.

* Add ovirt_storage_templates_facts

Adding fact module for storage templates.
The module should help with registering unregistered templates.

* Add ovirt_storage_vms_facts

Adding fact module for storage VMs.
The module should help with registering unregistered VMs.
7 years ago
Ryan S. Brown 2f3d9566f9 Remove exec bit on elb_application_lb module 7 years ago
René Moser fbcf6e23af yum: fix state=latest (#28547) 7 years ago
Jordan Borean 4382216e10 win_copy: changes that were missed (#28533) 7 years ago
Jordan Borean e631676546 fixed up win_robocopy return values (#28538)
* fixed up win_robocopy return values

* reduced lin size for validator
7 years ago
Sloane Hertel a48e0b5101 New Module to manage AWS direct connect link aggregation groups (#27250)
* Add module_utils/aws/direct_connect.py for frequently used functions

* new AWS Direct Connect link aggregation group module with tests and placebo recordings

* remove extra argument

* Remove use of undefined var

* Fix param name for extra exception codes for AWSRetry to use.

* Fix undefined var and line length and metadata version number

* Fix copyright headers
7 years ago
Eduard Iskandarov fe21dd272d Kubernetes PATCH operation (#19428)
* add patch_operation parameter for kubernetes module

* Fix test errors
7 years ago
Trishna Guha 4271f6e5e6 fix aggregate doc example (#28528)
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
7 years ago
Trishna Guha c2e41bf1ef remove net_command (#28525)
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
7 years ago
Martin Krizek 711ae03845 yum: fix reporting group changes in check_mode (#28331) 7 years ago
Felipe Garcia Bulsoni 84005498bc Support Fibre Channel over Ethernet resource of HPE OneView (#28359)
* Added new oneview_fcoe_network module and unit tests

* Fixing metadata issues and importing unittest from ansible.compat.tests

* Fixing shebang and adding correct copyright header

* Renamed remote_management/hpe to remote_management/oneview

* Updated documentation and default state according to review comments

- Added present as the default state
- Added delegate_to: localhost in all examples
- Changed config path from a variable to illustrate a location
- Other documentation fixes
7 years ago
Martin Krizek c59f3f841e yum: remove duplicite code introduced in d1fa210be (#28511) 7 years ago
Sloane Hertel cbb94a75fe Enable deleting IAM users with associated MFA devices. (#27288)
Refactore delete_user() since most of the heavy lifting was being done in the exception handling, which is not at all necessary and resulted in changed=False being shown after changes were successfully made.
7 years ago
Sloane Hertel 7551e8c921 AWSRetry: allow retrying on additional ClientError exceptions (#28483)
* Added the ability to extend the exception list in CloudRetry

* AWSRetry boto and boto compatible

* Updated tests to reflect boto/boto3

* Added boto to shippable requirements

* Have base_class and added_exceptions default to None in CloudRetry

AWSRetry - only retry on boto3 exceptions and remove boto requirement from tests

* Make requested changes.
7 years ago
Jordan Borean 9b7dbc78c3 win_wait_for: added module (#26556)
* win_wait_for: added module

* Increased timeout on async task

* added more debug messages for test debug

* revert to using win_shell instead of win_command

* rebased from master and updated copyright string

* Updated metadata version

* Capitalised start of short_description

* disabled win_wait_for tests until async issues are solved
7 years ago
Guido Günther 398f643c58 Check existence of SSL certs in Foreman callback (#25796)
* Fix typo

* foreman callback: check existence off SSL certs

This leads to confusing error messages later on otherwise.
7 years ago
Nathaniel Case e1def05ba2 fix networking *_command check_mode (#28407)
* Fix check_mode in nxos_command

* Fix check_mode for ios_command

* fix check_mode for iosxr_command

* Fix check_mode in vyos_command

* Fix check_mode in eos_command

* Fix check_mode in junos_config
7 years ago
Nathaniel Case 96abfde189 Fix idempotence for nxos_vrf_af (#28419) 7 years ago
Yanis Guenane f7f3f4b62c crypto: Add new module openssl_certificate (#28263)
This commit aims to add the openssl_certificate module.

This module allows a user to manage openssl certificates.
This module implement the notion of backend provider, making this module
extensible to anyone wish as long as a provider is coded for it.

The current three providers are the following:

  * selfsigned: Allows a user to self signed a certificate
  * acme: Allow a user to generate acme-based CA challenges certificate.
          (As of this writing this targets letsencrypt)
  * assertonly: Allow a user to assert the characteristic of her SSL
                certificate

Co-Authored-By: Markus Teufelberger <mteufelberger+ansible@mgit.at>
7 years ago
Rastislav Barlik f0a6f1637b Update xattr.py (#28458)
Fix wrong default value in documentation
7 years ago
Simon Dodsley 1fe71eacab Fix typo created in PR28485 (#28509) 7 years ago
Sloane Hertel f7e67dc3b1 Rename s3 module to aws_s3. Update CHANGELOG.md. (#28398)
Use aws_s3 in examples.
7 years ago
Brandon Davidson 2ceff476bf [cloud] support tags in ec2_group module (#22472)
* Add tags support to cloud/amazon/ec2_group

* Finish making ec2_group tag support boto3 compatible.

Add integration tests to validate that tags are working as expected.
7 years ago
Romain Dartigues 050de6d6b5 bug: lvol fail when LV already exists (#23635) 7 years ago
Tomáš Karásek b3a90253fc Improvements in the packet_device module (#23127)
* Improvements and fixes in the packet_device module

* add version_added to new args

* remove default value from facility

* changed 'lock' from deprecated arg to alias of 'locked'
7 years ago
Karol Chrapek 0954fadff7 Correct mute function in datadog_monitor (#19662) 7 years ago
Rene Moser 4a2b4d07db exoscale: similar env vars as in cloudstack
* update docs
7 years ago
Rene Moser 58cd107166 exoscale: fix api_key param auth typo 7 years ago
Ganesh Nalawade 5d1d1a72c5 Fix junos integration test failure (#28491)
Pass ssh_config value to ncclient manager api as None
if it is not set.
7 years ago
Dag Wieers 96da0047ac Fix an issue causing win_copy to fail
It seems win_copy can fail because `will_change` was not returned in the dictionary when doing a query.
This is an easy fix to get it working again.
7 years ago
tmarlok88 982e322287 java_cert role pkcs12 import (#24616)
* java_cert pkcs12 import

* documentation and formatting

* update examples

* update examples #2

* integration tests

* integration tests #2

* added aliases.txt

* renamed aliases

* bugfix

* empty it alieses
7 years ago
Dag Wieers 6d015294c2 purestorage: Various changes, and one check-mode fix (#28485)
These were the changes I propose twice, a nullified PR edit, and then as
review comments when the PR was being merged.

I made those changes now to all purestorage modules.
7 years ago
Simon Dodsley b150f49187 purefa_volume: Add volume copy, aka clone (#28376) 7 years ago
Abhijeet Kasurde 69d03d26e5 Fix multiple issues in vmware_vswitch (#27969)
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
7 years ago
Brian Coca a897193bce Moar constructive (#28254)
* made composite vars and groups generic

now you can do both in every plugin that chooses to suport it
renamed constructed_groups as it now also constructs vars ... to constructed
moved most of constructed_groups logic into base class to easily share

* documented inventory_hostname

* typo fix
7 years ago
Mike Wiebe ec11cd2696 nxos_bgp_neighbor_af fix problem with advertise-map properties (#28413)
* Fix problem with advertise-map properties

* Change limit_to back to run all tests

* Fix unit tests

* Move advertise_map out of get_custom_value
7 years ago
Dag Wieers d902b9a36e Fix booleans in win_psexec documentation 7 years ago
bonuscheese 7c366f5cbd Fix 'format' method syntax to support Python 2.6 (Fixes #28198) (#28304)
Fixes #28198
Changed how string format method is used to support Python 2.6 syntax. By adding in positional arguments to braces in format method (e.g. {0}, {1}), Python 2.6 can support this module, without causing issues in newer versions of Python.

See ref for info on format differences w/ 2.6:
https://docs.python.org/2/library/string.html#format-string-syntax
7 years ago
Matt Clay 44f4294f5c Fix metadata in syslogger module. 7 years ago
Tim Rightnour c1e4702ff4 Add the syslogger module
Remove tabs from docs

Pass ansible sanity test
7 years ago
Yanis Guenane d4e7b045b7 Extend test coverage for openssl modules (#27548)
* openssl_privatekey: Extend test coverage

Extend the coverage of the integration test for the module
openssl_privatekey.

New tests have been added:

  * passphrase
  * idempotence
  * removal

Co-Authored-By: Pierre-Louis Bonicoli <pierre-louis.bonicoli@gmx.fr>

* openssl_publickey: Extend test coverage

Extend the coverage on the integration test for the module
openssl_publickey.

New tests have been added:

  * OpenSSH format
  * passphrase
  * idempotence
  * removal
7 years ago
Emma 4653f892c8 Documentation fix - subnet_name (#28462)
virtual_network was incorrectly stated as an alias for subnet_name. It should be 'subnet'.
7 years ago
nrwahl2 535ede4d15 Fixes #28444: Renamed function print_match to match_print due to variable name conflict (#28445)
* Fixes #28444: Renamed print_match function to match_print due to name conflict

* Rename `match_print` to `do_print_match`

I think this is less confusing.
7 years ago
Dag Wieers b9cee65756 Original author wishes not to be notified by ansibot (#28447)
And moving maintainers to BOTMETA.yml as well.
7 years ago
David Kretch beed59f303 Fix trailing space in ec2_vol example, fix 'the the' typos (#28440)
* Fix 'the the' typos, fix 'pahting' filename typo

* Change 'the the' typos to a single 'the'.
* Change `playbook_pahting.rst` to `playbook_pathing.rst`.

* Delete trailing space in ec2_vol example

Delete the trailing space in `instance: "{{ item.id }} "`, which makes the
example fail when run because it looks for instance "i-xxxx ".
7 years ago
Mike b5a00d05d3 fixed #28183 - user module shadowfile update on SunOS (#28276)
* fixed #28183 - user module shadowfile update on SunOS
7 years ago
Jordan Borean 8e40ac54dd win_copy: rewrite with new tests and functionality (#27678)
* win_copy rewrite with new tests and functionality

* minor pep fixes

* Handle UTF-8 filenames in zip

* fix for template

* when zip assemblies are not available in .net revert to old behaviour of copying one by one

* typo fix

* some more typos

* updated logic to correctly handle when new directories can be created

* removed testing file as it is not needed

* updated documentation based on PR
7 years ago
Matt Clay 7fc4e6b4af Fix PEP 8 issue. 7 years ago
Brian Coca 49c54024e6 added helper function to convert objects to dicts 7 years ago
Brian Coca de16ce42ef optimize reserved names warning 7 years ago
René Moser b3a57a4014 cloudstack: cs_host: add host_tag alias (#28417) 7 years ago
Drew Bomhof ea51567697 Allow a miq token as an argument passed into the ManageIQ Python API Client (#28088) 7 years ago
Nathaniel Case 33f342435a Attempt to detect and abort when 'fex-fabric' is present (#28342) 7 years ago
Ganesh Nalawade 4f54d6cea1 eos aggregate spec validation and doc changes (#28414)
*  Add aggregate validation for eos DI modules
*  Doc change to add aggregate examples
7 years ago
Rene Moser f6b7c1a6c1 cloudstack: cs_storage_pool: fix state handling, add tests
cs_storage_pool: rm CloudStackException dependency

cs_storage_pool: fix UnboundLocalError in check mode
local variable 'pool' referenced before assignment
7 years ago
John McEleney 7549b27544 Add new module cs_storage_pool
- Changed zone_name to name - Changed cluster_name to cluster - Changed pod_name to pod - Corrected tags type in docs - Remove unneeded returns - Other simplifications
7 years ago
Abhijeet Kasurde be86d77a70 Add check for correct parsing of sysctl (#24540)
* PEP8 fixes
* Refactoring of code
* Check to skip non-comment lines which doesn't
  contain = character

Fixes #24453

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
7 years ago
Deyan Stoykov 2f732a621d haproxy: fix fail_on_not_found behaviour (#24790)
* haproxy: fix fail_on_not_found behaviour

* fix pep8 compliance
7 years ago
Dmitriy Khomutov 277b8bfaf0 Alternatives module: Add a check that the path to the executable exist (#24800)
* Add check that the path to the executable exists

* Corrected a typo
7 years ago
Sloane Hertel 29ab182537 elasticache_parameter_group: fix KeyError bug #24475 (#24509)
* Fix KeyError bug by appending None if key doesn't exist

ensure value is the expected type; if if expecting something parsed as truthy try to turn it back into the desired value - fixes result showing always changed since bool compared to str

use to_text

* use string_types instead of str, remove inline conditionals, abbreviate boolean logic
7 years ago
Guillaume Coré ccdea1c3b8 archive: allow ZIP64 by default (#24200)
allowZip64 is True by default since python 3.4,
see https://docs.python.org/3/library/zipfile.html#zipfile-objects

With python 2.7, when the file or folder to zip is >2G,
zipfile raises LargeZipFile.

This commit set allowZip64 to true.

Fixes #24125
7 years ago
Ganesh Nalawade c4b9dfe542 Remove default description in network DI modules (#28411) 7 years ago
Abhijeet Kasurde a572de626c Pep8 fixes for acl module (#24666)
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
7 years ago
Catatonic b146ba37da Update capabilities.py (#23879)
Fixes issue when using python3 interpreter: 'filter' object has no attribute 'append'
Ensure list type of data is used before appending data.
7 years ago
Konstantin Shalygin 343da35381 mail: Fix auth over starttls. (#24089) 7 years ago
Peter Sprygada 03b888052b fixes bugs in network filter for parsing ip address (#28404)
also adds parse_cli and parse_cli_textfsm to changelog
7 years ago
Gaige B Paulsen 54c50cc983 netconfig module updated to pay attention to .ssh/config (#23876) 7 years ago
Sloane Hertel b9762b52af s3_sync was setting HAS_BOTO3 by the existence of botocore alone. Fixes #28023 (#28339)
* s3_sync was setting HAS_BOTO3 by the existence of botocore alone. Fixed to import from module_utils.ec2 to ensure boto3 + botocore are present.

Also documented module requirements.

* Remove unused import
7 years ago
Bobby Watson 8e8a7c869a Changed string check to verify that EOS device is not in config mode. (#28332)
Changed string check to verify that EOS device is not in config mode. This was required in order to work with Arista 7500 series modular switches.
Resolves #2830
7 years ago
Chris Alfonso bd56e6c9ce Removing deprecated openswitch modules (#28397) 7 years ago
Doug Gorley 5e6984a34c Added support to GCE module for image families and external projects. (#26711)
* Added support to GCE module for image families and external projects.

* Added image_family and external_projects to gce_pd.

* Added version_added for new options.
7 years ago
Nathaniel Case db5d799122 Fix nxos_pim idempotence (#28348) 7 years ago
TaoBeier be6c4908a2 executor stats and task_executor pep8 error (#23651) 7 years ago
Abhijeet Kasurde 6fd579b9f5 Refactor DigitalOcean modules
Fix adds refactoring of DigitalOcean modules by adding
common functionality to module_utils.

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
7 years ago
Ganesh Nalawade 9ab9945cf3 iosxr modules aggregate check and other minor refactor (#28360)
*  iosxr aggregate validation
*  vyos_user, junos_user minor changes
*  Aggregated documentation
7 years ago
Ganesh Nalawade ceef4f97ed Use merge operation for load configuration in junos modules (#28369)
*  Change load configuration operation from replace to merge
7 years ago
Mehran Kholdi ecfa7f696d Enforce `state='file'` in `copy` module
This was causing wrong behaviour when `prev_state` was `hard`-link,
since the `file` module tried to apply the same `state` on the new
file, causing unexpected errors.

Particularly, both `overlay` and `devicemapper` storage drivers in
docker use hardlinks to share files between layers. This causes
most ansible playbooks to fail when working with files from layers
below.
7 years ago
Dag Wieers 78dfbed2a5 openbsd_pkg: Fix when failed, PEP8-compliant (#26018)
This PR includes:
- PEP8 compliancy
- A fix to ensure the module fails when it failed for a package
- Various cosmetic changes to documentation
- Make `state: present` the default (and not required)
7 years ago
Sam Doran 9fe898add6 Make options match others in the file 7 years ago
Kurt Bomya 05fd51f77d Added "choices" true/false for user_install 7 years ago
Julien Stroheker 0b29162b97 Azure Availability Set module (azure_rm_availabilityset) (#28353)
* Adding the module and int. tests

* upgrading metadata to 1.1
7 years ago
Sergio Millan 400085aa5b return EXCL_STATE when color property is not in the response 7 years ago
Artem Loginov 6e8eb7612a Fixed issue with legacy jenkins instances 7 years ago
Filipe Azevedo 6868c892ed Fixes https://github.com/ansible/ansible-modules-extras/issues/2462 (#21891) 7 years ago
Adrian Likins 01c0b2f714 Handle errors in jmespath in json_query better (#22109)
* Handle errors in jmespath in json_query better

Catch any exceptions raised from jmespath and raise
an AnsibleFilterError instead.

Avoid a traceback.

Fixes #20379

* pep8
7 years ago
Lukas Beumer eebc0cea6e [cloud][gcp] Add region and versioning parameter to gc_storage (#27802) 7 years ago
John Bond 722579356d correct handeling of execute option (#23814) 7 years ago
Nihlaeth e5ff8e3407 Don't remove comment from public key, and improve error message for duplicate keys (github_key) (#22282)
* improve error message for duplicate public keys

* don't consider self when searching for duplicates

* don't strip comment from key
7 years ago
Antony Messerli e0d0446183 Updates lldp module example to use ifname instead of ifalias (#23064) 7 years ago
Anthony Arnaud 3da1036baa zfs bad volume block size #23090 (#23092) 7 years ago
Elachance 7b8b444602 Fix logic in os_nova_host_aggregate module (#23191)
* Fix logic in os_nova_host_aggregate module

Fix logic around adding availability zone to metadata and comparing existing host list to parameter host list. 

Previously, when no availability zone was defined, an empty availability zone was being appended to metadata. This was causing 'empty named availability zone' errors when running the module against an already existing host aggregate with no availability zone. This was fixed by only appending availability zone to metadata if it is not an empty parameter.

Also added set() casting when comparing existing and new host lists. Previously, if existing host list was not in the same order as the host list in the .yml parameter file the module would consider this a change even if the two lists had the same entries.

* Update os_nova_host_aggregate.py
7 years ago
Michael Leer ce2c14757d the use of --puppet has been deprecated (#23356) 7 years ago
Sloane Hertel 25a9ababcc ec2.py: filter by client-token if id is specified (#26114)
fixes #26021
7 years ago
Sloane Hertel 1300680d30 [cloud] Cast port to an integer in elb_application_lb listener spec (#28341) 7 years ago
Dag Wieers e801187899 Bugfix and assorted fixes (#28352)
These are updates from aci-ansible.
7 years ago
disappear89 d4cedbee20 nmcli: Changed parameter ordering in create_connection_bond (#23571)
nmcli: Changed parameter ordering in create_connection_bond
7 years ago
Jun Guo 655667527d [docker] Fix ignore_image option not work issue. (#19039)
Currently the ignore_image option can be set, but can not work as it is
descripted in document. The reason is the code will check the difference
of configurations between current container and target image, and it
will mark the `different` to `True` when the image is different even we
set `ignore_image=true`, that will cause the container being re-create.
7 years ago
Simon Dodsley e7b0849886 Fix incorrect bool check in Pure Storage modules (#28007) 7 years ago
jctanner f4e93ccc1a Fix the authors in pure storage modules so the bot can ping the right users. (#28347) 7 years ago
Aleksandr Vinokurov a55cef3cba Fix `postgresql_user` module to treat quoted identifier well, Fixes #18937 (#18938) 7 years ago
Jasper Lievisse Adriaanse 955cc5a99e Fix for hponcfg on ESXi hypervisors (#27362)
Add new option to pass the path to the hponcfg binary which may not live in
$PATH. For example on ESXi hypervisors it tends to be located in
/opt/hp/tools/ instead. Also properly implement a verbose option for which the
code was already commented out.
7 years ago
Lucas Alvares Gomes 119a79cf0c Replace lxc-clone with lxc-copy (#19890) (#20373)
The command lxc-clone is deprecated in favor of lxc-copy. This patch
changes the lxc module to use the new lxc-copy command by default. If
not present, it will fallback to the old lxc-clone command to keep it
backward compatible with older versions of lxc.
7 years ago
alex lustenberg ff4fa6ac29 fix for empty hostnames in mysql users (#20523) 7 years ago
Jonathan Davila 974d988703 Updated consul_kv lookup plugin so that it can take in host and port
parameters as keyword arguments instead of only being able to specify
it as environment variables.
7 years ago
Alvaro Aleman f8e79eb481 Fix changed event for docker_image in force mode 7 years ago
Ryan Fitzpatrick b905a349ac Correct config manager deprecation warning 7 years ago
David Newswanger b818e986b6 Change network *_user modules to use configured_password to set a users password (#28187)
* WIP, update eos_user args

* refactor password for ios_user

* add eos tests, fix ios tests

* fixed password check

* refactor iosxr_user password

* fixed password arg for nxos

* [WIP] fix vyos_user password

* fix vyos tests

* update docs for net_user

* fix typo

* fix eos tests

* add warning when attempting to use password arg

* fix sanity/unit tests

* fix eos unit tests

* fix vyos_user aggregate

* fix typo in eos documentation string

* re add configured_password to vyos tests after rebase
7 years ago
Peter Sprygada b1d297d144 fixes asa_acl module to work with persistent connections (#28320)
* updates module_utils/asa.py to add missing common argument 'passwords'
* fixes asa_acl.py module to work with persistent connections
7 years ago
Abhijeet Kasurde 86f23dc620 Update connection logic in vmware module_utils (#26323)
Fix updates logic of connection in vmware module_utils

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
7 years ago
Ricardo Carrillo Cruz 5a6f3ebed1 WIP Implement declarative intent arguments on eos_vlan (#28270)
Implement declarative intent arguments on eos_vlan
7 years ago
Trishna Guha 2e211078ce fix vyos_user aggregate (#28317)
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
7 years ago
Ganesh Nalawade 403f6db53f ios aggregate and common argument support (#28316)
*  ios aggregate spec validation
*  ios common argument for aggregate support
7 years ago
Benjamin c9e5842c47 Fix maven_artifact documentation (#28295)
Display the string 'no' as default for the keep_name attribute.
7 years ago
Dag Wieers 2960f5feac Rename ACI modules according to new conventions (#28306)
As discussed in full at https://github.com/datacenter/aci-ansible
we desired a better naming convention for ACI modules before they ship
with Ansible v2.4

The result is summarized in this PR.

The modules now also include the classes from the object model, as well
as a link to the documentation.
7 years ago
Matt Clay 15be0e91e8 Fix PEP 8 issues. 7 years ago
Jordan Borean 46b80bc18e win_update: added extra job parameters to run even if on battery (#28212)
* win_update: added extra job parameters to run even if on battery

* added info about battery power change
7 years ago
kletiz a42b81132e win_dns_client failing on 2008R2 SP1 (Fixes #25216) (#28172) 7 years ago
Paulo Matias c8124ca39a os_router: fix checking if router needs update (#19780)
When verifying if a router needs update, the os_router module should
take into account only network ports which are owned by routers. Other
ports might have been added e.g. by the HA network tenant, which would
lead the router to always be detected as changed and cause the module to
try removing these network interfaces.
7 years ago
Meirong e75a256cfa add Fusionlayer Infinity ansible module into ansible package (#26855)
* add infinity ansible module into ansible package

* move infinity to be the correct direction without a folder

* remove dependency on requests library and use ansible built-in method to send rest api call

* add missing whitespace

* Use open_url from module_utils instead of urlopen based on suggestions

* correct the path for infinity ansible modue, moving it into the  ansible/modules/network/infinity

* make change on the documentation and code based on feedback

* change the data type in the Return documentation based on feedback

* add importing  for path and define metaclass based on testing failure

* change the postion of importing __future__

* Move Infinity module from Network module into net_tools directory based on review

* put back the file that is accidently removed

* change ansible-metadata version to be 1.1
7 years ago
Keisuke.K de27e8d228 nmcli should not return error if trying to delete an absent connection (#20677) 7 years ago
Andrew Klaus c9cfc9be07 os_recordset fix for names with multiple DNS record types (#19588)
* Fix for os_recordset.py to filter based on record type. Fixes https://github.com/ansible/ansible/issues/19572

* remove redundant variable

* Needing to use recordset ID to update and delete records. Using the record name for update/delete causes issues when A and AAAA records exist for a name

* Adding exception handling for dictionary item
7 years ago
George Nikolopoulos b339f23485 Various small fixes (#27766) 7 years ago
Anil Kumar Muraleedharan 55df3e05ed Solving Coverity issues (#28057) 7 years ago
Anil Kumar Muraleedharan ffd701c8d1 Resolving Coverity Issues. (#28056) 7 years ago
Mike Wiebe 8f4bc8150f Fix default nxapi port setting when use_ssl set (#28236)
* Fix port setting when use_ssl set
7 years ago
Martin Krizek bcb9644f39 yum: cover "Nothing to do" not only for groups (#28283) 7 years ago
Ganesh Nalawade 8a6e1531b7 Fix config timeout issue for network modules (#28261)
* Fix config timeout issue for network modules

* Re-enable network test

* Remove unwanted persistent connection timer

* Minor changes in description
7 years ago
Pilou 016cd0691c alternatives: handle absent link, add integration tests (#27967)
* alternatives: add integration tests

* alternatives: handle absent link (fix AttributeError)

Error occurred at least on Debian Stretch and OpenSuse 42.2:
Traceback (most recent call last):
  File "/tmp/ansible_RY6X41/ansible_module_alternatives.py", line 161, in <module>
    main()
  File "/tmp/ansible_RY6X41/ansible_module_alternatives.py", line 113, in main
    current_path = current_path_regex.search(display_output).group(1)
AttributeError: 'NoneType' object has no attribute 'group'

update-alternatives stdout sample:
dummy - manual mode
  link best version is /usr/bin/dummy1
  link currently absent
  link dummy is /usr/bin/dummy

* alternatives: PEP 8 fixes

* alternatives: fix copyright in integration tests

* alternatives: nested loops handle more than 2 items

Thanks to Michael Scherer (@mscherer) for pointing that.

* alternatives: enable integration tests
7 years ago
Peter Sprygada 6886153b54 refactors nxos_vrf_af module (#28208)
* refactors nxos_vrf_af module

fixes #27595

* fix up unit test cases

* add commands to result dict

* add route-target on afi create

* adds deprecation note to safi argument
7 years ago
Peter Sprygada 37524b798d updates network parse_cli filter to handle blocks from output (#28245)
* updates network parse_cli filter to handle blocks from output

* minor updates to finish up parse_cli filter

* all vars are now under the vars key
* attributes key has been changed to keys
* added the start_block and end_block directives

* update PEP8 failures
7 years ago
Yanis Guenane b658ea8da2 openssl_csr: Ensure array comparison is deterministic (#28265)
When comparing expected and current value for keyUsage and
extendedKeyUsage current behavior is not deterministic.

As we compare two arrays, based on the order the value have been
specified, False might be returned when the two arrays actually matches.
In order to have a deterministic comparison we compare sets rather than
arrays.
7 years ago
David Newswanger a37c5e53e6 fix prompt error when deleting ios user (#28175)
* fix prompt error when deleting ios user

* placate pep8

* wrap delete user command in function

* fix python 3 unit tests
7 years ago
Trishna Guha ce3d1c6ba0 eos_user fix username param (#28114)
* eos_user fix username param

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

* Add setup eos_user test and rename username for consistency

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

* update unit test and pep8 fix

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

* pep8 fix
7 years ago
Toshio Kuratomi d8b1cb9a63 Assign network modules maintained by the network team the network metadata 7 years ago
Toshio Kuratomi f203ca7907 Update metadata to 1.1 7 years ago
Toshio Kuratomi af2073d057 metadata 1.1
* Add network value to support_by field.
* New support_by value, certified
* Deprecate curated in favor of certified
* Add conversion from 1.0 to 1.1 to metadata-tool
* Add supported by Red Hat field to ansible-doc output
7 years ago
CyberArk BizDev d50d65d448 Added cyberarkpassword lookup plugin (#21857)
* Added cyberarkpassword lookup plugin

Added cyberarkpassword lookup plugin: It allows to retrieve credentials
(password, sshkey) from CyberArk Digital Vault
7 years ago
Toshio Kuratomi bf4858d042 metadata change was lost in conflict resolution. 7 years ago
Ganesh Nalawade 4caddad224 Doc fixes for junos lldp modules (#28228) 7 years ago
David Newswanger b7d886840b standardized agreggate as arg, and collection and users as aliases for user modules (#28244) 7 years ago
Dag Wieers edba563e9a ACI fixes (#28257) 7 years ago
Pierre-Louis Bonicoli 572ab3987a circonus_annotation: check requests library version 7 years ago
Pierre-Louis Bonicoli f69333b80d circonus_annotation: fix broken import, update requirements 7 years ago
Matt Davis 9b383403ce switch become/runas to LogonUser/CreateProcessWithTokenW (#28253)
* non-uac works

* switch become/runas to LogonUser/CreateProcessWithTokenW

* fixes #22218
* provides consistent behavior across authtypes
* auto-elevates on UAC if target user has SE_TCB_NAME ("Act as part of the operating system") privilege
* sets us up for much more granular capabilities later (eg, network/service/batch logons)
7 years ago
Pilou 1b6b74f655 alternatives: link is required when alternative is unknown (#27942)
Fixes #25598
7 years ago
Andy Freeland 9e8a3f4302 stdin arg: add documentation to shell module 7 years ago
Guillaume Coré 905c25559d add stdin argument to command module
fixes #14380
7 years ago
Jacob McGill b7d99f43d5 ACI EPG Contract Binding: New Module (#28251)
new module: managing EPG to Contract bindings [network/aci/aci_epg_contract_binding]
7 years ago
Toshio Kuratomi 872255b791 Revert "Add 'stdin' argument to command/shell modules"
This reverts commit 393909d0cc.
Reverte so that we can maintain authorship
7 years ago
schunduri 4729981eba new module: Manage end point groups [network/aci/aci_epg] (#28207)
* Cisco ACI EPG

* Fixed errors

* Updated module

* Update to version from aci-ansible repository
7 years ago
schunduri ebbb5369b5 new module: manage application network profiles [network/aci/aci_anp] (#27984)
* New Cisco ACI Application Profile Module

* PEP8 verified

* Various Fixes

* aci_anp:Refactored

* aci_anp changed short description

* Changes from the aci-ansible repository
7 years ago
schunduri 83d9f2d9ed new module: manage attachable entity profiles [network/aci/aci_aep] (#27987)
* New Cisco ACI Attachable Entity Profile Module

* PEP8 Verified

* Various Fixes

* Refactored: aci_aep

* Updated to the latest changes from aci-ansible

* And a small cosmetic change
7 years ago
Ozi Boms da3f8df20d Azure azure_rm_common update (#28227)
* include support for DNS modules

added code to allow DNS modules to run

* fixed issue with dns

* removed extra end of file line
7 years ago
Ivan Bojer c2b2176893 deprecated panos_nat_policy in lieu of panos_nat_rule (#28033)
* - deprecated panos_nat_policy in lieu of pano_nat_rule that uses next generation SDK (PanDevice). Also renamed the module so that is aligns with API calls and UI framework.

* - ansible_metadata requires metadata_version instead of just version key in 2.4

* PEP8 changes

* PEP8 changes

* Emit deprecation warning and add boilerplate
7 years ago
Andy Freeland 393909d0cc Add 'stdin' argument to command/shell modules
Fixes #14380 #23428
7 years ago
Brian Coca c27248db60 ansible-inventory cli tool (#22477)
* ansible-inventory cli tool

added vars dump to graph
made yaml inventory dump actual yaml inventory format
cleaner dump
fixed graph, no dump needed
add pulling in host/group vars
pep indentation crime
added docstring for manpage autodoc
remove ansible_facts from output
added api compat layer
allow import from new and old APIs
better conditional for <2.4
pe4+p4

test stuck on OS X (seems popular today) but passes rest, merging anyways
7 years ago
Ivan Bojer 178cf6e82e Rename panos_security_policy to panos_security_rule + extra features (#28031)
* - renamed panos_security_policy to panos_security_rule in order to better align with UI and API calls

* - fixed PEP8 issues

* - ansible bot does not like multiline comments. Using > for now.

* Add deprecation warning and boilerplate
7 years ago
Brian Coca f921369445 Ansible Config part2 (#27448)
* Ansible Config part2

- made dump_me nicer, added note this is not prod
- moved internal key removal function to vars
- carry tracebacks in errors we can now show tracebacks for plugins on vvv
- show inventory plugin tracebacks on vvv
- minor fixes to cg groups plugin
- draft config from plugin docs
- made search path warning 'saner' (top level dirs only)
- correctly display config entries and others
- removed unneeded code
- commented out some conn plugin specific from base.yml
- also deprecated sudo/su
- updated ssh conn docs
- shared get option method for connection plugins
- note about needing eval for defaults
- tailored yaml ext
- updated strategy entry
- for connection pliugins, options load on plugin load
- allow for long types in definitions
- better display in ansible-doc
- cleaned up/updated source docs and base.yml
- added many descriptions
- deprecated include toggles as include is
- draft backwards compat get_config
- fixes to ansible-config, added --only-changed
- some code reoorg
- small license headers
- show default in doc type
- pushed module utils details to 5vs
- work w/o config file
- PEPE ATE!
- moved loader to it's own file
- fixed rhn_register test
- fixed boto requirement in make tests
- I ate Pepe
- fixed dynamic eval of defaults
- better doc code

skip ipaddr filter tests when missing netaddr
removed devnull string from config
better becoem resolution

* killed extra space with extreeme prejudice

cause its an affront against all that is holy that 2 spaces touch each other!

shippable timing out on some images, but merging as it passes most
7 years ago
Ivan Bojer 8b617aaef5 Panos object (#28028)
* - deprecated panos_address and panos_service in lieu of common panos_object

* - deprecated/removed panos_address and panos_service in lieu for panos_object

* squash! - deprecated/removed panos_address and panos_service in lieu for panos_object

* - fixed PEP8 issues

* - ansible_metadata requires metadata_version instead of just version key in 2.4

* add > to multi line descriptions

* update version string to 2.4

* Update legacy-files.txt
7 years ago
Simon Dodsley 08767946cb Add Pure Storage Snap module (#28027)
* Add Pure Storage Snap module

* Use one line GPL license

https://github.com/ansible/community/wiki/Testing:-boilerplate,-wildcard-imports,-and-get_exception
7 years ago
saichint 064ab7a92d fix for remove idempotent issue (#28226) 7 years ago
Adrian Likins 8003437ebc prompt for new pass on create/encrypt if none specified (#28185)
* prompt for new pass on create/encrypt if none specified

Make 'ansible-vault' edit or encrypt prompt for a password
if none or provided elsewhere.

Note: ansible-playbook does not prompt if not vault password
is provided

* dont show vault password prompts if not a tty
7 years ago
giovannisciortino 09cc84c796 Fixes #27635: pam_limits fix add comment (#27999) 7 years ago
Sam Doran a8e4c9be7a Cause copy module to fail on empty string as source (#27975)
* Fail if an empty string is set as src for copy module

Fixes #27363

* Cleanup task formatting on copy tests

Use multi-line YAML
Add debug statements with verbosity: 1 rather than leave them in there commented out.

* Add test for empty string as source

* Do more checks in order to add more specific errors messages

Add more integration tests for the various failure scenarios.
Cleanup some syntax on existing integration test tasks.
7 years ago
saichint d69440c4ef Fix nxos_vpc issues (#28188)
* fix for nxos_vpc issues

* fix unit tests

* clean documentation
7 years ago
Nathaniel Case 1d13624eae Clean up nxos_aaa_server (#28177)
* cleanup nxos_aaa_server

* Specify nxos_aaa_server output format

Fixes #27289
7 years ago
Adrian Likins 5739bb075f Vault secrets default vault ids list (#28190)
* Add config option for a default list of vault-ids

This is the vault-id equilivent of ANSIBLE_DEFAULT_PASSWORD_FILE
except ANSIBLE_DEFAULT_VAULT_IDENTITY_LIST is a list.
7 years ago
Jiri Tyr 1b8fe94e5a Support list for baseurl and gpgkey params in yum_repository (fixes #24948) (#24967)
* Support list for baseurl and gpgkey params in yum_repository

* Adding tests
7 years ago
Nathaniel Case 20a35d0c1c Fix python3 str <-> bytes in connection/persistent.py (#28224) 7 years ago
Adrian Likins e287af1ac8 Vault secrets empty password (#28186)
* Better handling of empty/invalid passwords

empty password files are global error and cause an
exit. A warning is also emitted with more detail.

ie, if any of the password/secret sources provide
a bogus password (ie, empty) or fail (exception,
 ctrl-d, EOFError), we stop at the first error and exit. 

This makes behavior when entering empty password at
prompt match 2.3 (ie, an error)
7 years ago