From: Kienan Stewart Date: Thu, 11 Jul 2024 19:36:53 +0000 (-0400) Subject: ansible: Add option to template libvirt domains with EFI X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=9b8685884d173d937a8f2d19b2206d67f95b95d0;p=lttng-ci.git ansible: Add option to template libvirt domains with EFI Change-Id: I3f706634c81a193132b93cfc7b6cbae6ac795157 Signed-off-by: Kienan Stewart --- diff --git a/automation/ansible/roles/libvirt/templates/vm_template.xml.j2 b/automation/ansible/roles/libvirt/templates/vm_template.xml.j2 index 3313f30..495a6f0 100644 --- a/automation/ansible/roles/libvirt/templates/vm_template.xml.j2 +++ b/automation/ansible/roles/libvirt/templates/vm_template.xml.j2 @@ -7,6 +7,10 @@ {{ vm.vcpu }} hvm + {% if 'efi' in vm and vm.efi %} + /usr/share/OVMF/OVMF_CODE_4M.fd + /var/lib/libvirt/qemu/nvram/{% vm.name %}_VARS.fd + {% endif %} @@ -152,4 +156,4 @@
- \ No newline at end of file + diff --git a/automation/ansible/roles/libvirt/vars/main.yml b/automation/ansible/roles/libvirt/vars/main.yml index d988285..2dbd01d 100644 --- a/automation/ansible/roles/libvirt/vars/main.yml +++ b/automation/ansible/roles/libvirt/vars/main.yml @@ -7,8 +7,10 @@ vm_defaults: net_bridge: 'br102' # Non-default keys # cdrom: /path/to/file.iso - # uuid: xxxx-yyyy + # efi: true/false # name: xyz + # uuid: xxxx-yyyy + isos: - url: https://releases.ubuntu.com/jammy/ubuntu-22.04.4-live-server-amd64.iso checksum: "sha256:45f873de9f8cb637345d6e66a583762730bbea30277ef7b32c9c3bd6700a32b2"