From f3df03cffd20b4b4559ea352865e2efa6b1d7564 Mon Sep 17 00:00:00 2001 From: Molly Lau Date: Sun, 1 Oct 2023 04:10:01 +0900 Subject: [PATCH] Update RHELinit.sh --- Linux_reinstall/RedHat/RHELinit.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Linux_reinstall/RedHat/RHELinit.sh b/Linux_reinstall/RedHat/RHELinit.sh index 5d1cba2..4762a8b 100644 --- a/Linux_reinstall/RedHat/RHELinit.sh +++ b/Linux_reinstall/RedHat/RHELinit.sh @@ -87,6 +87,7 @@ wget --no-check-certificate -qO $cloudInitFile ''$cloudInitUrl'' # User config. sed -ri 's/HostName/'${HostName}'/g' $cloudInitFile sed -ri 's/tmpWORD/'${tmpWORD}'/g' $cloudInitFile +sed -ri 's/sshPORT/'${sshPORT}'/g' $cloudInitFile sed -ri 's/TimeZone/'${TimeZone1}'\/'${TimeZone2}'/g' $cloudInitFile sed -ri 's/networkAdapter/'${networkAdapter}'/g' $cloudInitFile if [[ "$iAddrNum" -ge "2" ]]; then @@ -124,7 +125,7 @@ sed -ri 's/^#?Port.*/Port '${sshPORT}'/g' /mnt/etc/ssh/sshd_config # Hack cloud init. utilProgram=$(find /mnt/usr/lib/python* -name "util.py" | grep "cloudinit" | head -n 1) sed -ri 's/iso9660/osi9876/g' $utilProgram -sed -ri 's/blkid/diklb/g' $utilProgram +sed -ri 's#"blkid"#"echo"#g' $utilProgram # Umount mounted directory and loop device. umount /mnt