mirror of
https://github.com/JasonN3/build-container-installer.git
synced 2025-12-25 10:57:55 +01:00
use other grub file
This commit is contained in:
parent
5c868dee23
commit
b5d5df4570
4 changed files with 10 additions and 6 deletions
|
|
@ -1,6 +1,6 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
FOUND_VERSION=$(grep VERSION_ID mnt/install/etc/os-release | cut -d= -f2)
|
FOUND_VERSION=$(grep VERSION_ID mnt/install/etc/os-release | cut -d= -f2 | tr -d '"')
|
||||||
|
|
||||||
if [[ ${FOUND_VERSION} != ${VERSION} ]]
|
if [[ ${FOUND_VERSION} != ${VERSION} ]]
|
||||||
then
|
then
|
||||||
|
|
|
||||||
|
|
@ -32,7 +32,7 @@ files/mnt/iso:
|
||||||
sudo mount -o loop ../../$(ISO_NAME) files/mnt/iso
|
sudo mount -o loop ../../$(ISO_NAME) files/mnt/iso
|
||||||
|
|
||||||
files/grub.cfg: files/mnt/iso
|
files/grub.cfg: files/mnt/iso
|
||||||
cp files/mnt/iso/boot/grub2/grub.cfg files/grub.cfg
|
cp files/mnt/iso/$(if $(_RHEL),isolinux/grub.conf,boot/grub2/grub.cfg) files/grub.cfg
|
||||||
sed -i 's/quiet/console=ttyS0,115200n8 inst.ks=cdrom:\/ks.cfg/' files/grub.cfg
|
sed -i 's/quiet/console=ttyS0,115200n8 inst.ks=cdrom:\/ks.cfg/' files/grub.cfg
|
||||||
sed -i 's/set default="1"/set default="0"/' files/grub.cfg
|
sed -i 's/set default="1"/set default="0"/' files/grub.cfg
|
||||||
sed -i 's/set timeout=60/set timeout=1/' files/grub.cfg
|
sed -i 's/set timeout=60/set timeout=1/' files/grub.cfg
|
||||||
|
|
@ -57,7 +57,7 @@ files/install.iso: files/grub.cfg
|
||||||
-compliance joliet_long_names
|
-compliance joliet_long_names
|
||||||
-map files/ks.cfg ks.cfg
|
-map files/ks.cfg ks.cfg
|
||||||
-chmod 0444 ks.cfg
|
-chmod 0444 ks.cfg
|
||||||
-map files/grub.cfg boot/grub2/grub.cfg
|
-map files/grub.cfg $(if $(_RHEL),isolinux/grub.conf,boot/grub2/grub.cfg)
|
||||||
-end
|
-end
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,6 @@
|
||||||
input.txt: gen_input.sh
|
input.txt: gen_input.sh
|
||||||
sed -i 's/quiet/quiet $(EXTRA_BOOT_PARAMS)/g' ../results/boot/grub2/grub.cfg
|
find
|
||||||
|
$(if $(wildcard ../results/boot/grub2/grub.cfg),sed -i 's/quiet/quiet $(EXTRA_BOOT_PARAMS)/g' ../results/boot/grub2/grub.cfg)
|
||||||
sed -i 's/quiet/quiet $(EXTRA_BOOT_PARAMS)/g' ../results/EFI/BOOT/grub.cfg
|
sed -i 's/quiet/quiet $(EXTRA_BOOT_PARAMS)/g' ../results/EFI/BOOT/grub.cfg
|
||||||
$(eval _VARS = ARCH FLATPAK_DIR IMAGE_NAME IMAGE_TAG ISO_NAME VERSION)
|
$(eval _VARS = ARCH FLATPAK_DIR IMAGE_NAME IMAGE_TAG ISO_NAME VERSION)
|
||||||
$(foreach var,$(_VARS),$(var)=$($(var))) bash gen_input.sh | tee input.txt
|
$(foreach var,$(_VARS),$(var)=$($(var))) bash gen_input.sh | tee input.txt
|
||||||
|
|
|
||||||
|
|
@ -14,8 +14,11 @@ do
|
||||||
then
|
then
|
||||||
continue
|
continue
|
||||||
fi
|
fi
|
||||||
echo "-map ${PWD}/${file} ${file:2}"
|
if [[ -f ${PWD}/${file} ]]
|
||||||
echo "-chmod 0444 ${file:2}"
|
then
|
||||||
|
echo "-map ${PWD}/${file} ${file:2}"
|
||||||
|
echo "-chmod 0444 ${file:2}"
|
||||||
|
fi
|
||||||
done
|
done
|
||||||
popd > /dev/null
|
popd > /dev/null
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue