# Need to write several files to help with various things here.
# First, the all-important README :
cat >/home/rocky/README << EOF
== Rocky 10 Raspberry Pi Image ==
This is a Rocky 10 install intended for Raspberry Pi 3b and 4 devices (architecture is aarch64).
This image WILL NOT WORK on a Raspberry Pi 1 or 2 (1.1 or earlier), we are 64-bit only, and have no support for 32-bit ARM processors. Sorry :-/.
The newer Pi Zero devices should be supported, as well as the Raspberry Pi 2 version 1.2 boards, which are 64-bit
IMAGE NOTES / DIFFERENCES FROM STOCK ROCKY 8:
- Based on Rocky Linux 10, points to production Rocky 10 aarch64 repositories
- Includes script that fixes the wifi. Simple edit of a txt firmware settings file. Will need to be run whenever linux-firmware gets upgraded
- Includes @minimal-install , plus a few quality of life packages like vim, bash-completion, etc.
- Initial User "rocky" (default password: "rockylinux"). Root password disabled, rocky user is a sudoer
- Partitions are 300 MB /boot , 512 MB swap, 2800 MB rootfs. Requires a 4 GB or larger storage device to serve as your disk
GROW YOUR PARTITION:
If you want to automatically resize your root (/ ) partition, just type the following (as root user):
sudo rootfs-expand
It should fill your main rootfs partition to the end of the disk.
Thanks for your interest on Rocky-on-Rpi, feel free to share your experience or contribute in our chat channel at: https://chat.rockylinux.org/rocky-linux/channels/altarch !
-The Rocky Linux Team
EOF
# Run the fix-wifi script (extracts the .xz firmware) - should be installed via the rocky-release-rpi package
# (shouldn't be needed anymore - fixed in newer rpi kernel builds)
#fix-wifi-rpi.sh
# Cleanup before shipping an image
# Remove ifcfg-link on pre generated images
rm -f /etc/sysconfig/network-scripts/ifcfg-link
# Remove machine-id on pre generated images
rm -f /etc/machine-id
touch /etc/machine-id
# Ensure no ssh keys are present
rm -f "/etc/ssh/*_key*"
# Clean yum cache
yum clean all
# Fix weird sssd bug, where it gets its folder owned by the unbound user: