diff options
author | Christian Pointner <equinox@spreadspace.org> | 2021-07-28 21:55:37 +0200 |
---|---|---|
committer | Christian Pointner <equinox@spreadspace.org> | 2021-07-28 21:55:37 +0200 |
commit | ef1d375723319e74ac0c7dde5a26606a55657c51 (patch) | |
tree | 3b06ec7f84d356d6820667c9614d012709f98280 /roles/vm/guest/define | |
parent | install emc-dist0 and emc-00 (diff) |
install emc-master
Diffstat (limited to 'roles/vm/guest/define')
-rw-r--r-- | roles/vm/guest/define/templates/libvirt-domain.xml.j2 | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/roles/vm/guest/define/templates/libvirt-domain.xml.j2 b/roles/vm/guest/define/templates/libvirt-domain.xml.j2 index 28f237a9..41671f73 100644 --- a/roles/vm/guest/define/templates/libvirt-domain.xml.j2 +++ b/roles/vm/guest/define/templates/libvirt-domain.xml.j2 @@ -58,6 +58,8 @@ <source dev='/dev/mapper/{{ src.vg | replace('-', '--') }}-{{ src.lv | replace('-', '--') }}'/> {% elif src.type == 'zfs' %} <source dev='/dev/zvol/{{ vm_host_cooked.zfs[src.backend | default('default')].pool }}/{{ vm_host_cooked.zfs[src.backend | default('default')].name }}/{{ inventory_hostname }}/{{ src.name }}'/> +{% elif src.type == 'image' %} + <source dev='{{ src.path }}'/> {% endif %} <target dev='{{ device }}' bus='virtio'/> </disk> @@ -73,6 +75,8 @@ <source dev='/dev/mapper/{{ src.vg | replace('-', '--') }}-{{ src.lv | replace('-', '--') }}'/> {% elif src.type == 'zfs' %} <source dev='/dev/zvol/{{ vm_host_cooked.zfs[src.backend | default('default')].pool }}/{{ vm_host_cooked.zfs[src.backend | default('default')].name }}/{{ inventory_hostname }}/{{ src.name }}'/> +{% elif src.type == 'image' %} + <source dev='{{ src.path }}'/> {% endif %} <target dev='{{ device }}' bus='scsi'/> </disk> |