collection of ansible roles
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

36 lines
705 B

{% for switch in vm_network %}
switch "{{ switch.name }}" {
interface "{{ switch.interface }}"
}
{% endfor %}
{% for vm in vms %}
vm "{{ vm.name }}" {
{% if auto_install_vms is defined %}
{% for file in auto_install_vms.files %}
{% if vm.name in file.path and not bootstrapped %}
disable
{% endif %}
{% endfor %}
{% endif %}
{% for disk in vm.disks %}
disk "{{ vm_dir }}/{{ disk.name }}"
{% endfor %}
{% for if in vm.interfaces %}
interface {
switch "{{ if.network }}"
{% for lladdr in vm_lladdr.results %}
{% if vm.name == lladdr.item.0.name %}
lladdr "{{ lladdr.stdout }}"
{% endif %}
{% endfor %}
}
{% endfor %}
memory {{ vm.mem }}
}
{% endfor %}