forked from ansible/ansible
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update TaskInclude _raw_params with the expanded/templated path to f…
…ile (ansible#39365) * Update TaskInclude _raw_params with the expanded/templated path to file * Add tests to validate host vars include paths
- Loading branch information
Showing
5 changed files
with
24 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 2 additions & 0 deletions
2
test/integration/targets/include_import/include_path_inheritance/one/include_me.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
- debug: | ||
msg: one |
14 changes: 14 additions & 0 deletions
14
test/integration/targets/include_import/include_path_inheritance/playbook.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
- hosts: testhost:testhost2 | ||
tasks: | ||
- set_fact: | ||
include_me: one | ||
when: inventory_hostname == ansible_play_hosts[0] | ||
|
||
- set_fact: | ||
include_me: two | ||
when: inventory_hostname == ansible_play_hosts[1] | ||
|
||
- debug: | ||
var: include_me | ||
|
||
- include_tasks: '{{ include_me }}/include_me.yml' |
2 changes: 2 additions & 0 deletions
2
test/integration/targets/include_import/include_path_inheritance/two/include_me.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
- debug: | ||
msg: two |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters