Commit graph

36354 commits

Author SHA1 Message Date
John R Barker
7764d9ce45
"route" has to be the first option in ufw command (#31756) (#40019)
* "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
(cherry picked from commit 21004d86f9)

* Changelog
2018-05-12 16:07:54 +01:00
John R Barker
6a46e3a44b
Backport/2.5/37847Fix interfaces_file to accept allow-* (#37847 (#40008)
* Fix interfaces_file to accept allow-* (#37847)

(cherry picked from commit 5ac41ee8d8)

* interfaces-file
2018-05-11 15:25:04 +01:00
Brian Coca
928e1e8f99 fix comma
(cherry picked from commit fc57f7bd5f)
2018-05-11 09:19:09 -04:00
Brian Coca
448999f10e fix keyword doc generation
* use aliases when they exist
  * fix hardcoded loop attributes handling

(cherry picked from commit 19fee0ef41)
2018-05-10 16:45:08 -04:00
Brian Coca
0cd5457ea2 remove properties from vars in include_role (#38968)
* remove properties from vars in include_role
* also from_ args

(cherry picked from commit b9f7f582d1)
2018-05-10 16:44:02 -04:00
Matt Clay
82abfa7ddf Mark the azure_rm_storageblob test unstable.
(cherry picked from commit 2de6734ce4)
2018-05-10 11:04:10 -07:00
zikalino
41532a2667 trying to fix storage blob timing issue
(cherry picked from commit 7284d40049)
2018-05-10 07:36:50 -07:00
Yuwei Zhou
3de89da6f0 Backport: Fixes some NIC bugs (#39213) (#39266)
* cherry-pick 1ecd2c9dcdb6df9baada84d220dddda3423137c2

* Create azure_rm_networkinterface-fix-creation-ignore-nsg-name.yaml
2018-05-10 19:43:26 +10:00
Chris Alfonso
fb669f76fb Backport/2.5/39027 (#39091)
* nios lookup errors out when there are no results #37970 (#39027)

* 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)

(cherry picked from commit fd50248463)

* Adding changelog mesage for nios lookup error
2018-05-10 10:08:44 +01:00
Alessandro Arnone
2107d91e45 [cloud] ec2_asg: wait for the lifecycle hooks - Fixes #37281 (#37282) (#39767)
* [cloud] ec2_asg: wait for the lifecycle hooks - Fixes #37281 (#37282)

Wait for the lifecycle hooks by matching states `Terminating:Wait` and `Terminating:Proceed` in addition to `Terminating`.

(cherry picked from commit ffd1200948)

* Add changelog fragment
2018-05-10 18:49:47 +10:00
Trishna Guha
fb26f6107d
nxos module doc fragment for authorize,auth_pass (#39946)
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
2018-05-10 13:34:10 +05:30
Matt Clay
1ecfca84e6 Make docs-build sanity test disabled by default.
(cherry picked from commit a7d7df1450)
2018-05-09 21:55:11 -07:00
Ewoud Kohl van Wijngaarden
c4a9989c87
Fix code snippet in playbook filters doc (#39798)
(cherry picked from commit e4efc191c5)
2018-05-10 12:05:51 +10:00
Matt Clay
651efdad1d Move lookups tests to group1.
(cherry picked from commit dec4f10c21)
2018-05-09 16:55:25 -07:00
Matt Clay
1fd024984b Overhaul httptester support in ansible-test. (#39892)
- Works with the --remote option.
- Can be disabled with the --disable-httptester option.
- Change image with the --httptester option.
- Only load and run httptester for targets that require it.

(cherry picked from commit c1f9efabf4)
2018-05-09 16:55:25 -07:00
Sam Doran
a8c823e813 Ensure timezone tests reset system timezone to original value (#39326)
(cherry picked from commit fda67bae50)
2018-05-09 16:01:12 -07:00
Robin Roth
f4dc8596fa Install git in pip tests (#39460)
* Install git in pip tests

* Ignore MacOSX

(cherry picked from commit 90354d282d)
2018-05-09 11:44:08 -07:00
Matt Clay
3fcb758a9c Remove CI group from unsupported tests.
(cherry picked from commit 0e344b225a)
2018-05-09 10:31:31 -07:00
Matt Clay
d24be2c6c6 Remove unnecessary destructive aliases.
(cherry picked from commit 6a1cb25c99)
2018-05-09 10:31:31 -07:00
Matt Clay
8d8409141a Mark unsupported vmware tests.
(cherry picked from commit 8e6fd48087)
2018-05-09 10:31:31 -07:00
John R Barker
a84312d9e3
Fix for NameError (#39665) (#39916)
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
(cherry picked from commit 3c32b483bc)
2018-05-09 17:36:04 +01:00
Alicia Cozine
1096fe568d
Update ios_system.py (#39623) (#39914)
<!--- Your description here -->
Typo in the example of `domain_search`, was `domain-search`should be `domain_search`
+label: docsite_pr
(cherry picked from commit 75304bd121)
2018-05-09 10:45:09 -05:00
Alicia Cozine
47dc15b841
Update panos_op.py (#39013) (#39912)
<!--- Your description here -->
The examples were apparently pasted from panos_object and the module name wasn't updated.
+label: docsite_pr
(cherry picked from commit 5f0e6b2dc3)
2018-05-09 10:44:51 -05:00
Alicia Cozine
add3004bb8
Update panos_security_rule.py (#39036) (#39911)
<!--- Your description here -->

+label: docsite_pr
(cherry picked from commit 2b2bfc8032)
2018-05-09 10:44:28 -05:00
Sam Doran
511d3110f7
Only change expiration date if it is different (#38885) (#39575)
* 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.

(cherry picked from commit 5a6bdef76b)
2018-05-09 10:45:48 -04:00
Abhijeet Kasurde
894830326a
Don't update cpu/memory allocation in configspec if there is no change. (#39865)
Fixes #38941

(cherry picked from commit 0296c8466a)
2018-05-09 18:37:03 +05:30
Martin Krizek
c485c439c7
Backport: apt: mark installed packages manual (#37751) (#39411)
(cherry picked from commit 00d9345158)
(cherry picked from commit 687f3bbef3)
2018-05-09 12:27:04 +02:00
Martin Krizek
5be6a3ef58 Auto install of python-apt without recommends. (#39409)
debian:9

`apt-get install python-apt` - this will install python2.7 and python3
After this operation, *88.4 MB* of additional disk space will be used.

`apt-get install --no-install-recommends python-apt` - only python2.7
After this operation, *35.0 MB* of additional disk space will be used.

(cherry picked from commit c542e62)
(cherry picked from commit 58261a42e9)
2018-05-09 04:51:38 -04:00
Matt Clay
df72a1d644 Move pyvmomi install into cloud test plugin.
(cherry picked from commit a5b8085113)
2018-05-08 12:27:37 -07:00
Nathaniel Case
f654d47c01
Remove provider (and transport, where applicable) from consideration when not using connection=local (#39555) (#39861)
* Remove provider (and transport, where applicable) from consideration

* Add tests that misplaced transport does not fail task

(cherry picked from commit c6270e15a6)
2018-05-08 12:54:03 -04:00
Trishna Guha
fb5bc5d513
nxos on_become terminal plugin stable_2.5 (#39852)
* 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>
(cherry picked from commit f08332acb4)

* nxos on_become changelog

Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
2018-05-08 15:52:09 +05:30
Deepak Agrawal
c23aa1c9ce
show version brief does not work on iosxr virtual (#39847)
* show version brief does not work on iosxr virtual (#37609)

* show version brief does not work on iosxr virtual

* ci failures fix

(cherry picked from commit 66b389a00d)

* changelog entry
2018-05-08 13:12:23 +05:30
Trishna Guha
079b7cb1fe
nxos and ios bugfix stable-2.5 (#39845)
* nxos_linkagg normalize interface (#39591)

Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
(cherry picked from commit 3c35dd4f7f)

* use show run instead of section pipeline ios_l2_interface (#39658)

Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
(cherry picked from commit dddcbb7198)

* add changelog

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

* fix nxos_snmp_user issues (#39760)

* fix nxos_snmp_user issues

* shipppable fix

(cherry picked from commit e3bfbe5875)

* changelog

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

* fix shippable

Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
2018-05-08 12:38:22 +05:30
Deepak Agrawal
54a229adb9
Handling of configurations blocks with end-* at the end of the block (#39843)
* 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

(cherry picked from commit ef577b71cc)

* changelog entry
2018-05-08 11:34:53 +05:30
Ganesh Nalawade
4b979742fa
Fetch ios default config is defaults is enabled (#39741) (#39841)
If default option is eanbled fetch the current
running configuration by adding `all` or `full`
flag
(cherry picked from commit 09e3b5c92b)
Update Changelog
2018-05-08 10:11:54 +05:30
Alicia Cozine
e1fde2a50f
Update call method for parse_cli_textfsm (#38437) (#39827)
+label: docsite_pr
(cherry picked from commit 7f5820274f)
2018-05-07 22:13:02 -05:00
Martin Krizek
00662ef044 Backport release_and_maintenance.rst (#39755)
* document our deprecation (#37788)

* document our deprecation

fixes #37779

* Copy edit.

(cherry picked from commit 8b45cab3c1)

* Update docs and version definitions for the 2.4.4 and 2.5.0 releases

(cherry picked from commit 73c80862c8)

* Fix 2.5 changelog link

(cherry picked from commit 4165bb308b)
2018-05-07 22:09:11 -05:00
Andrew Gaffney
8e5956a98b Backport #39818 to stable-2.5 (#39824)
* Update vars for loop_control on each loop iteration (fixes #38899) (#39818)

(cherry picked from commit 01e8139d74)

* Changelog snippet for cherry-pick of #39818
2018-05-07 19:09:48 -04:00
John R Barker
bf1436ca52 facts: Detecting NVME partitions under Linux (#39730) (#39804)
* 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>
(cherry picked from commit 2214c747a2)

* 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

(cherry picked from commit 75283983f6)
2018-05-07 14:18:53 -07:00
Charles
17f7d35b32
Broken link to MSDN (#39814)
Fix broken link to MSDN site for FileSystemRights enumeration

+label: docsite_pr

(cherry picked from commit ea7883ef7e)
2018-05-08 05:50:26 +10:00
Matt Clay
515ab5fd99 Restore nuage_vspk integration tests.
(cherry picked from commit 1c7417cba7)
2018-05-07 11:32:50 -07:00
Matt Martz
4d245c9a87
Backport #39764 for 2.5 - async_status environment (#39766)
* Make sure that the implicit async_status gets the env from a task with async. Fixes #39699 (#39764)

(cherry picked from commit 3b496db4d8)

* Add changelog for #39764
2018-05-07 10:02:18 -05:00
Abhijeet Kasurde
5016ea8615
vmware_guest: cast vlan to int or str when relevant (#39793)
`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

Signed-off-by: Matthieu Fronton <m@tthieu.fr>
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>

(cherry picked from commit a0b4462aea)
2018-05-07 16:45:18 +05:30
Ganesh Nalawade
20e8766840
Fix eos_config integration test failure (#39662) (#39784)
Enable become for eos_config check_mode test cases
(cherry picked from commit b20b964c4a)
2018-05-07 09:03:19 +05:30
Matt Clay
b711bde6b2 Temporarily disable the nuage_vspk test.
This test interferes with the uri test on centos6.

(cherry picked from commit a121b5073c)
2018-05-05 14:01:03 -07:00
Alicia Cozine
831cfe9164
doc for _config backup argument (#38650) (#39763)
(cherry-picked from commit 6de49f0)
2018-05-04 17:33:08 -05:00
Artem Goncharov
81abf7837d Backport/2.5/39371 Issue 30786 (#39660)
* Fixes 30786 - add server response to the failure

(cherry picked from commit 0ac885f1c7546caa5b9178b142f490d211167f5a)

* replace str(e) with to_native(e) according to code review

(cherry picked from commit e2e3bf6b9ae44d565baeaa7d7d1ab853888d8c7a)

* add changelogs/fragments
2018-05-04 12:55:40 -04:00
Ganesh Nalawade
8d570e67db
Fix eos_vlan associated interface check (#39661) (#39738)
* 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

* Update changelog
(cherry picked from commit afdc2364f2)
2018-05-04 20:14:48 +05:30
Ganesh Nalawade
cf374ca9d4
Fix ios integration test failures in CI (#39729) (#39731)
Fix ios integration test failures in CI. Since the packet transfer and receive rate
on the interface is not determined to remove the tx_rate and rx_rate test conditions
to prevent intermittent failure.
(cherry picked from commit 4c5ac16447)
2018-05-04 17:30:03 +05:30
Trishna Guha
69564206e0
nxos bugfixes stable-2.5 (#39719)
* Handle nxos_feature issue where json isn't supported (#39150)

Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
(cherry picked from commit 9eff1f1d74)

* Integration Tests only: nxos_snmp_contact (#39318)

* add integration test cases for snmp_contact

* removing unnecessary files

(cherry picked from commit bdb75cd82c)

* fix nxos_ntp issues (#39178)

* fix nxos_ntp issues

* review comments

* fix idempotent fail case

(cherry picked from commit 2f99a17856)

* nxos_interface: AttributeError: 'NoneType' object has no attribute 'group' (#38544)

This fixes an issue we recently encounteredi with nxos_interface:

```
Traceback (most recent call last):
  File "/tmp/ansible_JmLoba/ansible_module_nxos_interface.py", line 777, in main
    have = map_config_to_obj(want, module)
  File "/tmp/ansible_JmLoba/ansible_module_nxos_interface.py", line 606, in map_config_to_obj
    obj['speed'] = re.search(r'speed (\d+)', body).group(1)
AttributeError: 'NoneType' object has no attribute 'group'
```

(cherry picked from commit dca6e2d94d)

* fix nxos_snmp_community issues (#39258)

(cherry picked from commit 1afec5a48e)

* Add aggregate example in nxos_l2_interface module doc (#39275)

Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
(cherry picked from commit 86817cdd52)

* Fix misuse of 'self' in lib/ansible/module_utils/network/eos/eos.py. … (#39074)

* Fix misuse of 'self' in lib/ansible/module_utils/network/eos/eos.py. Method load_config

* Fix all instances of self.config(self,...

(cherry picked from commit 80d7e22f5e)

* Fix for nxos_snmp_host issues (#39642)

* fix snmp_host issues

* source files

* fix shippable

* remove defaults to match arg spec

(cherry picked from commit f99bae1776)

* fix nxos_snmp_traps issues (#39444)

* fix snmp_traps code

* add IT cases

* fix shippable

* fix shippable without ignore

(cherry picked from commit 99748cbfa4)

* changelog

Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
2018-05-04 15:25:55 +05:30