added nvme to rootfs-expand & set hostname

This commit is contained in:
Bryan Zuelly 2024-10-29 12:04:39 +00:00
parent 43dff877cf
commit c1dc484762

View File

@ -737,6 +737,9 @@ EOF
chmod 644 /etc/default/grub chmod 644 /etc/default/grub
rm -f /boot/dtb rm -f /boot/dtb
###set hostname so it can be found on the network
echo "rockyaltarch" > /etc/hostname
cat >/usr/local/bin/rootfs-expand << EOF cat >/usr/local/bin/rootfs-expand << EOF
#!/bin/bash #!/bin/bash
clear clear
@ -748,7 +751,7 @@ fi
dev=\$(echo \$part|sed 's/[0-9]*\$//g') dev=\$(echo \$part|sed 's/[0-9]*\$//g')
devlen=\${#dev} devlen=\${#dev}
num=\${part:\$devlen} num=\${part:\$devlen}
if [[ "\$dev" =~ ^/dev/mmcblk[0-9]*p\$ ]];then if [[ "\$dev" =~ ^/dev/(mmcblk|nvm3[0-9]+n)[0-9]*p\$ ]];then
dev=\${dev:0:-1} dev=\${dev:0:-1}
fi fi
if [ ! -x /usr/bin/growpart ];then if [ ! -x /usr/bin/growpart ];then