diff options
author | Christian Pointner <equinox@spreadspace.org> | 2021-07-01 01:21:02 +0200 |
---|---|---|
committer | Christian Pointner <equinox@spreadspace.org> | 2021-07-01 01:21:02 +0200 |
commit | 8ef2f52313f5affce1614c9eee27d6466fc6f46d (patch) | |
tree | 56e34c4bb3aa83f7779182a6762e15202d410d77 /roles/installer/ubuntu/usb/templates/grub.cfg.j2 | |
parent | fix reusability of subiquity based usb installer (diff) |
ubuntu usb installer can now install multiple hosts from same drive
Diffstat (limited to 'roles/installer/ubuntu/usb/templates/grub.cfg.j2')
-rw-r--r-- | roles/installer/ubuntu/usb/templates/grub.cfg.j2 | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/roles/installer/ubuntu/usb/templates/grub.cfg.j2 b/roles/installer/ubuntu/usb/templates/grub.cfg.j2 index a9a1761c..1f97113a 100644 --- a/roles/installer/ubuntu/usb/templates/grub.cfg.j2 +++ b/roles/installer/ubuntu/usb/templates/grub.cfg.j2 @@ -8,11 +8,15 @@ fi set menu_color_normal=white/black set menu_color_highlight=black/light-gray +{% if (ansible_play_hosts_all | length) == 1 %} set timeout=10 set default=0 +{% endif %} +{% for host in ansible_play_hosts_all %} -menuentry "automated installer for {{ inventory_hostname }}" { +menuentry "automated installer for {{ host }}" { set gfxpayload=keep - linux /casper/vmlinuz quiet nopersistent autoinstall "ds=nocloud;s=/cdrom/autoinstall/" {{ (install_cooked.kernel_cmdline | default([])) | join(' ') }} + linux /casper/vmlinuz quiet nopersistent autoinstall "ds=nocloud;s=/cdrom/autoinstall/{{ host }}/" {{ (hostvars[host].install_cooked.kernel_cmdline | default([])) | join(' ') }} initrd /casper/initrd } +{% endfor %} |