-
Feature Request
-
Resolution: Unresolved
-
Undefined
-
None
-
2.5, 2.6
-
None
-
False
-
-
False
Description
Nodes within a child workflow should inherit variables provided by the parent workflow.
Not inheriting variables means considerable additional configuration must be done to workflows to achieve the desired results.
Steps to Reproduce
1. I created a job template 'Test' with a playbook.
- name: Hello World Sample
hosts: all
tasks: - name: Hello Message
debug:
msg: "{{ msg }}"
2. I created a Workflow template 'Child' with job template 'Test' and Project sync 'Demo Inventory'
I mentioned an extra variable 'msg: Hello Susmitaaa'
3. I created a workflow template 'Parent' with Workflow template 'Child' and Job template 'Test'.
I mentioned an extra variable 'msg: Hello Susmita!'
4. When I launched 'Child' the job template shows output.
TASK [Hello Message] *********************************************************** 8:15:55 AM
7
ok: [localhost] =>
5. When I launched 'Parent' workflow template.
The child shows output.
TASK [Hello Message] *********************************************************** 8:16:25 AM
7
ok: [localhost] =>
10
But the job template 'Test' output changed.
TASK [Hello Message] *********************************************************** 8:16:28 AM
7
ok: [localhost] =>
Actual Behavior
The defined extra variable in the parent workflow template doesn't get inherited by the child workflow template.
Expected Behavior
The child workflow template should inherit the extra variables from the parent workflow template.
Additional Context