I am trying to use a delegate_to in a play where the delegated-to host is 
the (only) member of a group, where the groupname is 'slurm-prictlr'. The 
play looks like:

- name: Ensure MUNGE key from Slurm primary controller is on this client
  synchronize:
    src: /etc/munge/munge.key
    dest: /etc/munge/munge.key
  delegate_to: $item
  with_items: "{{ groups.slurm-prictlr[0] }}"
  when: "'slurm-prictlr' not in group_names"

However, when I run the playbook with this play on a host, I'm getting:

fatal: [myhost]: FAILED! => {
    "msg": "'prictlr' is undefined"
}

Are hyphens in group names the problem? Or what else may be the problem 
here?

-- 
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/b9cb6d71-573b-446d-8299-631e4db3b9d6%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to