Look up the mac in hostvars

Signed-off-by: Patrick Uiterwijk <puiterwijk@redhat.com>
This commit is contained in:
Patrick Uiterwijk 2018-08-20 21:06:12 +00:00
parent 8dd249daac
commit f671e1c428

View file

@ -42,7 +42,7 @@
- tftp_server
- name: generate custom configs
template: src=grubhost.cfg dest="/var/lib/tftpboot/uefi/{{ item.install_mac }}"
template: src=grubhost.cfg dest="/var/lib/tftpboot/uefi/{{ hostvars[item].install_mac }}"
with_items: "{{ groups['all'] }}"
when: "hostvars[item].install_noc == inventory_hostname"
tags: