Hi Fedora community,

Fedora on RPI is AMAZING and I'm working on a project to automate provisioning 
for a Raspberry Pi cluster. This would add a ton of CI capabilities and 
convenience. It would also take the edge of the nuisance that RPIs eat SD cards 
like I eat Oreos.
Right now the process is pretty manual:

1. Put SD card in secondary machine
2. DD Fedora's minimal aarch64 image onto SD card
3. Grow partition
4. Put SD card back
5. Boot
6. Go through initial setup
7. Update all packages
8. Continue with regular config and host management

This requires being physically in front of the RPIs (and provisioning machine) 
and involves a lot of hand holding.

I'd like to make this process as headless as possible so that re-kicking a RPI 
is as easy as "setting a flag", rebooting and waiting for the RPI to come back 
up freshly installed.
Right now I have the following path in mind how this could potentially work:

The network interface of the RPI3B+ is capable of PXE booting, yay! So I'm 
thinking something along the lines of:

1. DHCP
2. Load files through TFTP (bootcode.bin -> start_x.elf -> DTB(?) -> 
u-boot.bin/IPXE -> kernel -> initramfs)
3. Boot kernel/initramfs which fires up Anaconda
4. Install Fedora normally
5. Use %post to copy device tree files to /boot and do other things necessary 
to make the RPI boot

If this worked, provisioning would be as easy as:

(0. Create DHCP reservation)
1. SD card into RPI
2. Turn on RPI
3. Login via SSH/VNC/etc.

I managed to boot U-Boot, chain load iPXE (probably not necessary since U-Boot 
is capable enough) but when pulling the regular aarch64 vmlinuz/initrd.gz 
pxeboot images it just errors out with an error saying "Invalid application". 
My knowledge about the kernel/initramfs chain gets blurry here which is why all 
tries in altering the initrd.gz image have failed gloriously.

If we can make this possible I'd be happy to turn it into a Wiki page so that 
others can extend their RPI environment with unattended provisioning.

Happy memorial to everyone celebrating and thank you for your interest!
Vascko
_______________________________________________
users mailing list -- users@lists.fedoraproject.org
To unsubscribe send an email to users-le...@lists.fedoraproject.org
Fedora Code of Conduct: https://getfedora.org/code-of-conduct.html
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/users@lists.fedoraproject.org

Reply via email to