I have a requirement to create directories in UNIX based on group of 
windows hosts. Plan is to create a playbook1 which runs against windows 
inventory and set a list/array using set_stats module and utilize this 
variable in playbook2 to create directories in UNIX. Below is the script i 
am using as of now and end result is one directory with one big string 
which is concatenation of all windows hosts names. 

Can you help in approach of creating list dynamically and setting the stat.

Playbook runs on Windows - name: set hostname in a variable set_stats: 
data: current_hostname: "{{ ansible_hostname }}" per_host: no Playbook runs 
on Unix name: Creates UNIX directory file: path: "{{ ARCH_DIR_LOC + 
current_hostname + '/'}}" state: directory mode: 0777

Thank you,
Revanth

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Development" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to ansible-devel+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to