This does not seem to work:
---
- hosts:
- "*westus_azure_ops*"
vars:
X: "{{ groups['splunk_cluster_label_westus_azure_ops'] | random_choice
}}"
tasks:
- debug: var=X
no filter named 'random_choice' is likely the error tripping us up
On Tuesday, October 23, 2018 at 11:18:14 AM UTC-4, Brian Coca wrote:
>
> for the first, the random_choice filter seems to be what you want:
> ```
> anynode: "{{ groups['shc_hosts']|random_choice }}"
> ```
> for the 2nd something like:
> ```
> urllist: "{{ groups['shc_hosts']|map('regex_replace', '^(.*)$',
> 'https://'')|list|join(':8089,')}}:8089"
> ```
>
> --
> ----------
> Brian Coca
>
--
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/23a9b468-b229-455d-917c-bebeb29bb7b5%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.