Compare commits

...

6 Commits

Author SHA1 Message Date
a48cf0cb0d New release 2.5.0b1 2018-02-08 18:44:30 -08:00
ff7b627b8e CHANGELOG module/plugin updates for 2.5 2018-02-08 17:51:45 -08:00
1f49fa2129 stub 2.6 in devel CHANGELOG, update 2.5 info 2018-02-08 17:06:52 -08:00
c1c5433733 Fix for #31477: return 'dest' from copy when file wasn't changed
(cherry picked from commit 89ad40b129)
2018-02-08 16:18:36 -08:00
e55e5cf23e Address memory ballooning caused by task caching changes (#35921)
* Exclude parent when copying included task to avoid memory issues. Fixes #35796

* Simplify implicit block squashing to pre-group, instead of post re-parenting

(cherry picked from commit 7d1eb88ecf)
2018-02-08 15:28:38 -08:00
71c053bd8c branch stable-2.5 2018-02-08 14:34:14 -08:00
7 changed files with 71 additions and 43 deletions

View File

@ -3,7 +3,7 @@ Ansible Changes By Release
<a id="2.5"></a>
## 2.5 "TBD" - ACTIVE DEVELOPMENT
## 2.5 "Kashmir" - March 2018 (estimated)
[Porting Guide](http://docs.ansible.com/ansible/devel/porting_guides.html)
@ -78,24 +78,34 @@ See [Porting Guide](http://docs.ansible.com/ansible/devel/porting_guides.html) f
### New Plugins
## Lookups
* aws_ssm: Query AWS ssm data
#### Lookups
* aws_account_attribute: Query AWS account attributes such as EC2-Classic
availability
* aws_service_ip_ranges: Query AWS IP ranges for services such as EC2/S3
* aws_ssm: Query AWS ssm data
* config: Lookup Ansible settings
* conjur_variable: Fetch credentials from CyberArk Conjur
* k8s: Query the K8s API
* nios: Query Infoblox NIOS objects
* openshift: Return info from Openshift installation
* redis: look up date from Redis DB, deprecates the redis_kv one.
## Callbacks
#### Callbacks
* null
* unixy
* yaml
## Connections
* network_cli
#### Connections
* kubectl
* netconf
* network_cli
* oc
While neither is technically a new plugin, these connections may now be used directly with network modules. See [Network Best Practices for Ansible 2.5](http://docs.ansible.com/ansible/devel/network_best_practices_2.5.html) for more details.
While neither network_cli nor netconf are technically new plugins, these connections may now be used directly with network modules. See [Network Best Practices for Ansible 2.5](http://docs.ansible.com/ansible/devel/network_best_practices_2.5.html) for more details.
## Filters
#### Filters
* parse_xml
### New Modules
@ -122,8 +132,8 @@ While neither is technically a new plugin, these connections may now be used dir
* cloudfront_distribution
* cloudfront_invalidation
* cloudfront_origin_access_identity
* cloudwatchlogs_log_group
* cloudwatchlogs_log_group_facts
* cloudwatchlogs_log_group.py
* ec2_ami_facts
* ec2_asg_lifecycle_hook
* ec2_customer_gateway_facts
@ -131,7 +141,6 @@ While neither is technically a new plugin, these connections may now be used dir
* ec2_placement_group
* ec2_placement_group_facts
* ec2_vpc_egress_igw
* ec2_vpc_vpn
* ecs_taskdefinition_facts
* elasticache_facts
* elb_target
@ -168,10 +177,15 @@ While neither is technically a new plugin, these connections may now be used dir
- misc
* terraform
- oneandone
* oneandone_firewall_policy
* oneandone_load_balancer
* oneandone_monitoring_policy
* oneandone_private_network
* oneandone_public_ip
* oneandone_server
- openstack
* os_keystone_endpoint
* os_project_access
- ovirt
* ovirt_api_facts
* ovirt_disk_facts
@ -270,12 +284,8 @@ While neither is technically a new plugin, these connections may now be used dir
* aci_encap_pool_range
* aci_fabric_node
* aci_firmware_source
* aci_interface_policy_fc
* aci_interface_policy_leaf_policy_group
* aci_interface_policy_leaf_profile
* aci_interface_policy_lldp
* aci_interface_policy_mcp
* aci_interface_policy_port_security
* aci_interface_selector_to_switch_policy_leaf_profile
* aci_static_binding_to_epg
* aci_switch_leaf_selector
@ -292,6 +302,12 @@ While neither is technically a new plugin, these connections may now be used dir
* avi_gslbservice_patch_member
* avi_wafpolicy
* avi_wafprofile
- dimension data
* dimensiondata_vlan
- edgeos
* edgeos_command
* edgeos_config
* edgeos_facts
- enos
* enos_command
* enos_config
@ -312,6 +328,7 @@ While neither is technically a new plugin, these connections may now be used dir
* bigip_device_trust
* bigip_gtm_server
* bigip_iapplx_package
* bigip_monitor_http
* bigip_monitor_https
* bigip_monitor_snmp_dca
* bigip_monitor_udp

View File

@ -1 +1,2 @@
2.5.0 0.0.devel
2.5.0b1

View File

@ -160,7 +160,7 @@
<div class="DocSiteProduct-logoText">
Ansible
<div class="DocSiteProduct-CurrentVersion" align="right">
devel
2.5
</div>
</div>
</div>

View File

@ -48,29 +48,38 @@ def load_list_of_blocks(ds, play, parent_block=None, role=None, task_include=Non
block_list = []
if ds:
for block_ds in ds:
b = Block.load(
block_ds,
play=play,
parent_block=parent_block,
role=role,
task_include=task_include,
use_handlers=use_handlers,
variable_manager=variable_manager,
loader=loader,
)
count = iter(range(len(ds)))
for i in count:
block_ds = ds[i]
# Implicit blocks are created by bare tasks listed in a play without
# an explicit block statement. If we have two implicit blocks in a row,
# squash them down to a single block to save processing time later.
if b._implicit and len(block_list) > 0 and block_list[-1]._implicit:
for t in b.block:
if isinstance(t._parent, (TaskInclude, IncludeRole)):
t._parent._parent = block_list[-1]
else:
t._parent = block_list[-1]
block_list[-1].block.extend(b.block)
else:
block_list.append(b)
implicit_blocks = []
while block_ds is not None and not Block.is_block(block_ds):
implicit_blocks.append(block_ds)
i += 1
# Advance the iterator, so we don't repeat
next(count, None)
try:
block_ds = ds[i]
except IndexError:
block_ds = None
# Loop both implicit blocks and block_ds as block_ds is the next in the list
for b in (implicit_blocks, block_ds):
if b:
block_list.append(
Block.load(
b,
play=play,
parent_block=parent_block,
role=role,
task_include=task_include,
use_handlers=use_handlers,
variable_manager=variable_manager,
loader=loader,
)
)
return block_list

View File

@ -538,13 +538,13 @@ class ActionModule(ActionBase):
changed = changed or module_return.get('changed', False)
# the file module returns the file path as 'path', but
# the copy module uses 'dest', so add it if it's not there
if 'path' in module_return and 'dest' not in module_return:
module_return['dest'] = module_return['path']
if module_executed and len(source_files['files']) == 1:
result.update(module_return)
# the file module returns the file path as 'path', but
# the copy module uses 'dest', so add it if it's not there
if 'path' in result and 'dest' not in result:
result['dest'] = result['path']
else:
result.update(dict(dest=dest, src=source, changed=changed))

View File

@ -763,7 +763,8 @@ class StrategyBase:
elif not isinstance(data, list):
raise AnsibleError("included task files must contain a list of tasks")
ti_copy = included_file._task.copy()
ti_copy = included_file._task.copy(exclude_parent=True)
ti_copy._parent = included_file._task._parent
temp_vars = ti_copy.vars.copy()
temp_vars.update(included_file._args)
# pop tags out of the include args, if they were specified there, and assign

View File

@ -19,5 +19,5 @@
from __future__ import (absolute_import, division, print_function)
__metaclass__ = type
__version__ = '2.5.0'
__version__ = '2.5.0b1'
__author__ = 'Ansible, Inc.'