Call for help: Installer changes for UEFI

Hello,

with UEFI patch merged, some changes for our installer needs to be done.
I am searching for Puppet expert/volunteer to do quite small changes in
the smart-proxy module which would take me weeks of hacking (I don't
know Puppet syntax and best practices):

The tracking ticket for this task is:
http://projects.theforeman.org/issues/12635

if RHEL6 or Fedora 18 or older is found then
install grub package
create /var/lib/tftproot/grub/
copy /boot/efi/EFI/*/grub.efi to /var/lib/tftproot/grub/grubx64.efi
copy also shim.efi file
ensure correct file permissions and SELinux context

if RHEL7 or Fedora 19 or newer is found then
install grub2-efi package
create /var/lib/tftproot/grub2/
copy /boot/efi/EFI/*/grubx64.efi to /var/lib/tftproot/grub2/grubx64.efi
copy also shim.efi file
ensure correct file permissions and SELinux context

if Debian is found then
download http://ftp.debian.org/debian/dists/jessie/main/installer-amd64/current/images/netboot/debian-installer/amd64/bootnetx64.efi (replace "jessie" with correct distro name)
create /var/lib/tftproot/grub2/
copy it to /var/lib/tftproot/grub2/grubx64.efi
create a relative symlink shim.efi to grubx64.efi
ensure correct file permissions

if Ubuntu is found then
download http://archive.ubuntu.com/ubuntu/dists/trusty/main/uefi/grub2-amd64/current/grubnetx64.efi.signed (replace "trusty" with correct distro name)
create /var/lib/tftproot/grub2/
copy it to /var/lib/tftproot/grub2/grubx64.efi
create a relative symlink shim.efi to grubx64.efi
ensure correct file permissions

Additionally, change dhcpd.conf template and add if statement described
here: Feature #14920: Change dhcpd.conf to support EFI loaders - Installer - Foreman

(*) - this path element can be either redhat, centos, fedora or scientific

Please ping me if you are willing to help, I want to focus on
Ubuntu/Debian PXEGrub1 and 2 template changes. Time is ticking for the
next stable release! :slight_smile:

References:

RHEL6 and RHEL7 documentation
https://wiki.ubuntu.com/UEFI/PXE-netboot-install
https://www.debian.org/distrib/netinst#netboot

··· -- Later, Lukas #lzap Zapletal

Lukas,

··· > On 26.08.2016, at 10:41, Lukas Zapletal wrote: > > > if Debian is found then > download http://ftp.debian.org/debian/dists/jessie/main/installer-amd64/current/images/netboot/debian-installer/amd64/bootnetx64.efi

I think, we should not depend on downloads from the (evil/firewalled) internet.
What do you think of packaging this?
We should at least make the mirror url configurable.

> I think, we should not depend on downloads from the (evil/firewalled) internet.

I agree, but it does not appear to be present in Debian repos.

> What do you think of packaging this?

Not so keen about it. But it's an option for sure.

> We should at least make the mirror url configurable.

Absolutely.

··· -- Later, Lukas #lzap Zapletal

> > I think, we should not depend on downloads from the (evil/firewalled) internet.
>
> I agree, but it does not appear to be present in Debian repos.

I actually found a way how to build EFI grub from modules, updated the
description:

http://projects.theforeman.org/issues/12635

Looks like some decent Puppet code needs to be written :slight_smile:

··· -- Later, Lukas #lzap Zapletal