I'm sure this is dead simple, but googling seems hard since most posts
contain the words "role" and "variable"!
I have versioned playbooks. I would like to stick a file somewhere on the
target system that explains what role was used, a time stamp, and a
version. I use maven as it happens. I thought I could something like this:
roles/install_iod_base/tasks/pom.yml
- name: copy the pom for this trunk/branch/tag
copy: src=../../../../pom.xml dest=~/pom.xml-{{ ansible_date_time.date
}}-{{ ansible_date_time.time }} mode=0644
I would like to include this snippet in all my roles, and therefore it
would be useful to have something like
copy: src=../../../../pom.xml dest=~/pom.xml-*{{ ansible_role }}*-{{
ansible_date_time.date }}-{{ ansible_date_time.time }} mode=0644
How can I enumerate the current roles name?
--
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/8865c77e-9e5f-4695-b643-cb1a17281d79%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.