Hello,
I am new to ansible, i have requirement.
vars:
locations:
- parentlocation: A
childlocation:
- a1
- a2
- a3
- parentlocation: B
childlocation:
- b1
- b2
- b3
Now i want run task so
- name: create parent location
command:
some command '{{ parentlocation }}' create
- name: create child loc aslo pass parent of it
command:
some command '{{ parentlocation }}' --child '{{ childlocation[0,1,3..]
How do i iterate ??
Basically i wilk create parent locatuon and when i create child location i need
to pass its parent as well so it creates hierarchies
Thanks,
Dj
--
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/560fb268-cc3b-4d97-a0db-910678c045dd%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.