mirror of https://github.com/ansible/ansible.git
Properly template tags in parent blocks (#81624)
When templating tags (which happens outside of standard `post_validate`) we need to template each object in the inheritance chain and set the templated values on those objects individually. That way when `task.tags` is called the `extend` functionality properly picks up the templated values of all parents into one flatten list. Fixes #81053pull/79687/merge
parent
304e63d76e
commit
9b3ed5ec68
@ -0,0 +1,2 @@
|
||||
bugfixes:
|
||||
- Properly template tags in parent blocks (https://github.com/ansible/ansible/issues/81053)
|
@ -0,0 +1,10 @@
|
||||
- hosts: localhost
|
||||
gather_facts: false
|
||||
vars:
|
||||
tags_in_var:
|
||||
- tag1
|
||||
tasks:
|
||||
- block:
|
||||
- name: Tagged_task
|
||||
debug:
|
||||
tags: "{{ tags_in_var }}"
|
Loading…
Reference in New Issue