Hi all,
I'm trying to do the following;
group_vars/all.yml
A_variable: ping
B_variable: pong
playbook.yml
- hosts: all
roles:
- role: A
- role: B
A/meta/main.yml
...
dependencies:
- { role: B, B_variable: "{{ A_variable }}" }
This however does not work. I can't seem to pass a variable from A to B
this way (error). If i do B_variable = A_variable in de defaults or vars of
the A role the first run of B does use A_variable, but the second run (at
master level) also uses A_variable while i want it to use B_variable.
I want to reuse the logic of B in A but without revealing this to the end
user. A extends B and both should be applied on the same host with
different vars.
I can't seem to figure this out.. any ideas?
Kind regards,
Gertjan Roggemans
--
You received this message because you are subscribed to the Google Groups
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/ansible-project/e934517c-7f67-479a-a5c2-32c3cb144458%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.