--- - name: Configure the webmail hosts: webmail roles: - { role: webmail, imapsvr: "{{ hostvars[groups.IMAP[0]] }}" }