Commit graph

38188 commits

Author SHA1 Message Date
mjmayer
b60fc33eef Add execution_role_arn parameter (#41849)
* Add execution_role_arn parameter

* Change ecs_taskdefinition to use AnsibleAWSmodule

Botocore version checking is becomming more common. Changing the ecs_taskdefinition
to use AnsibleAWSmodule allows more easily for this.

* Change launch type check to use botocore_at_least function

* Remove execution_role_arn param from params dict

* Change check to use parameter

* Fix typo

* Add test for old botocore version

* Add test for execution role parameter

* Remove iam_role_facts task

Task was unecessary. The same information could be gathered by registering
the iam_role task.
2018-07-04 14:34:11 +10:00
fxfitz
f92b95b8cb Remove ipa_ modules from sanity ignore; fix the docs 2018-07-03 18:16:09 -07:00
cahlchang
92dce2943f [AWS] Add check Iam Role description update (#39773)
* add check description update

* Ensure 'Description' is in the role so KeyError isn't caused

* Fix changed when modifying the description with check mode
2018-07-03 18:01:14 -04:00
Dag Wieers
459cdef993
Fix integration tests aliases (#42245) 2018-07-03 23:41:58 +02:00
Toshio Kuratomi
ae55e9f5d6 fix changelog (#42272) 2018-07-03 14:31:19 -04:00
Kevin Breit
ecfaf3ba75 Meraki integration test block and cleanup (#42254)
* Added block and always support to meraki_network integration test

* Add blocks to admin and vlan integration test

* Resolved bad variable names
2018-07-03 18:35:42 +02:00
Manu Pascual
313e7ba55e Fix set the correct key option in the docs (#42251)
In vmware_vmkernel, parameter is subnet_mask instead of netmask
2018-07-03 20:12:51 +05:30
Deepak Agrawal
febf88c81b
test file required for ios_files tests (#42248) 2018-07-03 19:54:05 +05:30
Trishna Guha
805d13f287
nxos CI failures bugfix (#42240)
* fix nxos_portchannel and remove deprecated param in test

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

* fix _nxos_switchport CI failures

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

* fix nxapi nxos_command test

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

* remove unsupported param nxos_smoke test

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

* fix nxos_vxlan_vtep_vni

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

* syntax error

Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
2018-07-03 19:45:19 +05:30
Trishna Guha
0e05425b32
Refactor nxos cliconf get_device_info and add requirements for JSON structured output support in nxos_facts module (#42089)
* nxos_facts requires JSON structured output support

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

* refactor get_device_info for legacy devices

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

* update additional logic

Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
2018-07-03 19:44:50 +05:30
Ondra Machacek
0a6ab23f38 ovirt_affinity_lables_facts: Raise error when host/vm not found (#41790) 2018-07-03 10:04:51 -04:00
Ashish Billore
faa83285dc Udate ini.py with corrected intended use (#42232)
* Udate ini.py with corrections to intended use

Corrected the intended use for ini reads.

* Update ini.py with corrected intended use info
2018-07-03 08:48:43 -04:00
krisek
55a94784a3 Update aci_vrf.py (#42246)
<!--- Your description here -->

+label: docsite_pr
2018-07-03 14:27:48 +02:00
Kevin Breit
f9cbdcd426 Meraki - Integration tests now clean up on failure (#42227)
* Added block and always support to meraki_network integration test

* Add blocks to admin and vlan integration test

* Resolved bad variable names
2018-07-03 10:42:04 +02:00
Dag Wieers
75c8d8bfc2
Fix aci_tenant module references
<!--- Your description here -->

+label: docsite_pr
2018-07-03 10:39:46 +02:00
Kevin Breit
05f7d64a98 Add properties for orgs and nets (#42085)
- Module utility now has orgs, nets, org_id, and net_id properties
- get_nets and get_orgs sets nets and orgs properties respectively
- Allows for storage of this data in the module. org_id and net_id aren’t set as I cannot guarantee that’s always desired.
2018-07-03 10:23:12 +02:00
Kevin Breit
08ddd202fb meraki_config_template - Check for HTTP status code (#42145)
* Check for HTTP status code

- All requests now check returned status code
- Fail if status code isn’t what is expected

* Fix blank line error

* Change HTTP check logic and improve integration tests
- Set HTTP status code check so default path is accept
- Added create and delete network for integration test
- Remove a few comments to clean up code
2018-07-03 04:26:56 +02:00
Kevin Breit
40b9862d38 Meraki modules - Added support for checking HTTP response codes (#42144)
* Added support for checking HTTP response codes
- All request calls now check for response code before responding
- If the response code isn't what it should be, it fails or returns nothing
- Breaking this into multiple PRs to make backporting easier
- Using status property in Meraki module utility which has the code

* Change logic of HTTP checks so success is default
2018-07-03 04:24:06 +02:00
Kevin Breit
3ee3fc893d Change idempotency check to be single pass (#42087)
- Previously all data between both data structures was compared
- Results in situations where updates are done when not needed
- Changes to single pass so only data in payload is compared
2018-07-03 04:20:36 +02:00
Dag Wieers
09fec5a482
aci_interface_policy_ospf: Create OSPF interface policies (#42184)
* aci_interface_policy_ospf: Create OSPF interface policies

New module to create OSPF interface policies

* Fix documentation issues

* Add missing integration tests

* Update documentation and examples
2018-07-03 04:04:48 +02:00
Dag Wieers
57c0471b54
Fix ACI validate-modules issues (#42222) 2018-07-03 04:04:35 +02:00
David Galloway
9539284010 nsupdate.py: Fix typo (#42209)
Signed-off-by: David Galloway <dgallowa@redhat.com>
2018-07-02 13:03:37 -07:00
tstoner
db7300904d Enforcing NXAPI default HTTP behavior (#41817)
* nxos_nxapi http default behavior

* Use nxos_nxapi module in prepare_nxos_tests

* Refactor nxos_nxapi configure test to use yaml block

* Extend nxos_nxapi https & http test cases

* Removed NXOS internal release naming

* Resolved ansibot sanity errors

* Fix typo in prepare_nxos_tests

* Address PR comments

* Shippable indicates this is no longer needed

* Add port change logic and testing
2018-07-02 14:58:37 -04:00
Rob
b87e1a023d [aws] add support for http2 to AWS ALB (#40372) 2018-07-02 14:31:56 -04:00
Andrew Gaffney
21b99bff94
Fix 'ansible-doc' command in action plugin docs (#42206) 2018-07-02 13:26:46 -05:00
Alexander Saprykin
1eea5674ba Fix galaxy client executing queries with invalid http method (#42201)
Fixes: ansible/galaxy#796
2018-07-02 12:37:40 -04:00
Brian Coca
d497eba196 several FAQ updates and clarifications 2018-07-02 10:46:59 -04:00
jeromecc
daaf711e44 clarify module functionality in docstrings: module creates domains and their @ A record only #35669 (#41872) 2018-07-02 10:36:51 -04:00
Abhijeet Kasurde
087fc0c20c Restore BOOLEANS import in basic.py (#42008)
This import was removed by mistake. This is required for backward
compatibility.

Fixes: #41988

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2018-07-02 10:27:16 -04:00
fluxcess
6290a7c595 added description (#42187)
Added description to one of the really basic code examples

+label: docsite_pr
2018-07-02 10:10:27 -04:00
Trishna Guha
981c9f6a79
fix nxos_vxlan_vtep_vni issue (#42183)
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
2018-07-02 19:32:29 +05:30
Nathaniel Case
a197125954
Nxos restore provider to nxapi tests (#41818)
* Quick and dirty sed to add provider

* Manually verify the rest of the cases

* Add missing provider
2018-07-02 09:43:51 -04:00
Ganesh Nalawade
1659951710
Fix eos integration test failure (#42188)
* Fix error message in eos_config integration test
* Fix set_become invoke login in httpapi connection plugin
2018-07-02 18:49:45 +05:30
cclauss
14bc625c2c Catch the raised exception so we can report failure (#42177)
[AWS iam_policy] Avoid the _undefined name_ by catching the raised exception into the variable __e__ so it can be reported on the following line.

flake8 testing of https://github.com/ansible/ansible on Python 3.6.3

$ __flake8 . --count --select=E901,E999,F821,F822,F823 --show-source --statistics__
```
./lib/ansible/modules/cloud/amazon/iam_policy.py:305:16: F821 undefined name 'e'
            if e.errno == 2:
               ^
./lib/ansible/modules/cloud/misc/rhevm.py:594:24: F821 undefined name 'e'
            setMsg(str(e))
                       ^
./lib/ansible/modules/files/archive.py:391:92: F821 undefined name 'e'
                module.fail_json(dest=dest, msg='Error deleting some source files: ' + str(e), files=errors)
                                                                                           ^
3    F821 undefined name 'e'
3
```
2018-07-02 08:45:36 -04:00
Nathaniel Case
5850591d14
Base connection class for network-style connections (#41839)
* Create base class for network-style connections

* clean up some differences

* Move NetworkConnectionBase

* Tweak netconf for tests

* Tweak when network_os is checked to avoid failing tests

* Pull back exec_command
2018-07-02 08:41:00 -04:00
Kevin Breit
380d08af5d Fix integration tests (#42088)
- Integration test assertions had some invalid variables
2018-07-02 10:47:57 +02:00
Kevin Breit
dd31dcab70 Meraki module utility request() has improved error reporting (#39838)
* request() has improved error reporting
- 5xx errors show same as before
- 3xx and 4xx errors show error body

* Print body for errors greater than 300, but less than 500

* Remove trailing whitespace
2018-07-02 10:42:50 +02:00
cclauss
61d5454737 Catch the raised exception so we can report failure (#42072)
Avoid the _undefined name_ and mirror lines 389 and 459 by catching the raised exception in the variable __exc__ so it can be reported on the following line.

flake8 testing of https://github.com/ansible/ansible on Python 3.6.3

$ __flake8 . --count --select=E901,E999,F821,F822,F823 --show-source --statistics__
```
./lib/ansible/module_utils/network/iosxr/iosxr.py:414:42: F821 undefined name 'exc'
            module.fail_json(msg=to_text(exc))
                                         ^
```
2018-07-02 09:36:10 +05:30
Felix Fontein
52e7946de5 Minimizing information needed for second stage from first stage. (#42167) 2018-07-01 10:06:38 -04:00
Andrew Gaffney
f4efa2c4cc
Provide a fallback value for all options in 'default' callback plugin (#42155)
This is necessary for plugins that subclass 'default' but don't also
include its docs fragment. This is a follow-up to #41058
2018-06-30 21:31:30 -05:00
Sviatoslav Sydorenko
fc25d280be
Add CoC and mailing lists links to PYPI
PR #42101
2018-06-30 22:55:50 +03:00
Sam Doran
fb55038d75 Add warning when using an empty regexp in lineinfile (#42013)
* Revert "Account for empty string regexp in lineinfile (#41451)"

This reverts commit 4b5b4a760c.

* Use context managers for interacting with files

* Store line and regexp parameters in a variable

* Add warning when regexp is an empty string

* Remove '=' from error messages

* Update warning message and add changelog

* Add tests

* Improve warning message

Offer an equivalent regexp that won't trigger the warning.
Update tests to match new warning.

* Add porting guide entry for lineinfile change
2018-06-29 17:15:43 -07:00
Brian Coca
b6f2aad600 ignore ansible.cfg in world writable cwd (#42070)
* ignore ansible.cfg in world writable cwd
 * also added 'warnings' to config
 * updated man page template
2018-06-29 16:46:10 -07:00
Brian Coca
de0e11c0d5 avoid loading vars on unspecified basedir (cwd) (#42067)
* avoid loading vars on unspecified basedir (cwd)
2018-06-29 16:45:38 -07:00
Matt Clay
c3134ce6e2 Temporarily switch RHEL and Windows tests to AWS. 2018-06-29 16:23:54 -07:00
James Cassell
3627aa3391 pamd module regression fix (#42025)
* pamd: typo fix sufficicent->sufficient

* pamd: is_valid is a property, not a method; return a tuple

* pamd: define is_valid for all PamdLine classes

* pamd: use validate() for verbose errors, define generically

* pamd: PamdRule: rule_control is always str, use _control

Fixes https://github.com/ansible/ansible/issues/41179
2018-06-29 16:34:20 -05:00
Olli-Antti Kivilahti
8eacbd0381 elasticsearch_plugin - Show STDERR on module failures. (#41954)
* elasticsearch_plugin - Show STDERR on module failures.

I tried to install a ES plugin without
  become: yes
and found after debugging the module that the module failed ude to permission issues.

The only error message I got was
  Is analysis-icu a valid plugin name?

That was strange considering I followed the example documentation by the letter.

I found out that when this module fails, it hides the real reason for failure.

This patch replaces the generic error with more meaningful diagnostics.

* elasticsearch_plugin - Show STDERR on module failures. Changelog fragment

 samdoran commented 2 days ago

This looks good. Please create a changelog fragment to go along with this change. See fragments for examples.
2018-06-29 17:28:17 -04:00
Tyler Gregory
fabd7823b2 Correct typo in win_domain_computer doc (#42123) 2018-06-29 23:05:07 +02:00
Sloane Hertel
22a6927dbd Fix file module with check_mode - Fixes #42111 (#42115)
* Fix file module check_mode
2018-06-29 11:19:34 -07:00
John R Barker
e9dbebfa57
Fix some broken links (#42079)
* Fix some broken links

* We now only serve via https
* redirects don't work with anchors, so update those links (devel/dev_guide)
2018-06-29 11:12:01 -07:00