install bootloader correctly

This commit is contained in:
f 2022-06-18 22:42:29 -03:00
parent 55c3c5f052
commit d835871964

View file

@ -4,11 +4,11 @@
src: "templates/update-extlinux.conf.j2"
dest: "/mnt/etc/update-extlinux.conf"
mode: "0644"
- name: "Update configuration"
shell: "PATH=/usr/bin:/usr/sbin:/bin:/sbin chroot /mnt /sbin/update-extlinux"
- name: "Install bootloader in MBR. This is how `setup-disk` does it."
shell: "cat /mnt/usr/share/syslinux/mbr.bin > {{ disk_device }}"
- name: "Install syslinux configuration into /boot using chroot."
shell: "PATH=/usr/bin:/usr/sbin:/bin:/sbin chroot /mnt /sbin/extlinux --install /boot"
- name: "Update configuration"
shell: "PATH=/usr/bin:/usr/sbin:/bin:/sbin chroot /mnt /sbin/update-extlinux"
- name: "Generate initramfs."
shell: "PATH=/usr/bin:/usr/sbin:/bin:/sbin chroot /mnt /bin/sh -c 'ls /lib/modules | xargs /sbin/mkinitfs -K'"