got rid of preseed file altogether
This commit is contained in:
parent
d445a64bd0
commit
4e63fa26bf
|
@ -58,7 +58,7 @@ mkdir $PROJECTPATH/ubuntu-overssh-iso
|
|||
cp -rT /mnt/ubuntu-overssh-iso $PROJECTPATH/ubuntu-overssh-iso
|
||||
|
||||
# create preseed
|
||||
cp $PROJECTPATH/preseed.cfg.template $PROJECTPATH/ubuntu-overssh-iso/preseed.cfg
|
||||
#cp $PROJECTPATH/preseed.cfg.template $PROJECTPATH/ubuntu-overssh-iso/preseed.cfg
|
||||
|
||||
# replace vairables
|
||||
sed -i 's/timeout 0/timeout 150/g' $PROJECTPATH/ubuntu-overssh-iso/prompt.cfg
|
||||
|
@ -69,16 +69,16 @@ sed -i 's/timeout 0/timeout 150/g' $PROJECTPATH/ubuntu-overssh-iso/isolinux.cfg
|
|||
#sed -i "s/INTERFACE_NAMESERVERS/$INTERFACE_NAMESERVERS/g" $PROJECTPATH/ubuntu-overssh-iso/preseed.cfg
|
||||
#sed -i "s/INTERFACE_NETMASK/$INTERFACE_NETMASK/g" $PROJECTPATH/ubuntu-overssh-iso/preseed.cfg
|
||||
#sed -i "s/INTERFACE_GATEWAY/$INTERFACE_GATEWAY/g" $PROJECTPATH/ubuntu-overssh-iso/preseed.cfg
|
||||
sed -i "s/COUNTRY_LOWER/$COUNTRY_LOWER/g" $PROJECTPATH/ubuntu-overssh-iso/preseed.cfg
|
||||
sed -i "s/COUNTRY/$COUNTRY/g" $PROJECTPATH/ubuntu-overssh-iso/preseed.cfg
|
||||
#sed -i "s/COUNTRY_LOWER/$COUNTRY_LOWER/g" $PROJECTPATH/ubuntu-overssh-iso/preseed.cfg
|
||||
#sed -i "s/COUNTRY/$COUNTRY/g" $PROJECTPATH/ubuntu-overssh-iso/preseed.cfg
|
||||
#sed -i "s/HOSTNAME/$HOSTNAME/g" $PROJECTPATH/ubuntu-overssh-iso/preseed.cfg
|
||||
#sed -i "s/DOMAIN/$DOMAIN/g" $PROJECTPATH/ubuntu-overssh-iso/preseed.cfg
|
||||
sed -i "s/PASSWORD/$PASSWORD/g" $PROJECTPATH/ubuntu-overssh-iso/preseed.cfg
|
||||
#sed -i "s/PASSWORD/$PASSWORD/g" $PROJECTPATH/ubuntu-overssh-iso/preseed.cfg
|
||||
|
||||
sed -i "s#append #append priority=critical auto=true #g" $PROJECTPATH/ubuntu-overssh-iso/txt.cfg
|
||||
sed -i "s#append #append priority=critical auto=true debian-installer/locale=en_US debian-installer/language=en debian-installer/country=$COUNTRY debian-installer/locale=en_US.UTF-8 netcfg/choose_interface=auto hw-detect/load_firmware=true anna/choose_modules=network-console network-console/password=$PASSWORD network-console/password-again=$PASSWORD #g" $PROJECTPATH/ubuntu-overssh-iso/txt.cfg
|
||||
#sed -i "s#append #append priority=critical auto=true preseed/url=$PRESEED_URL netcfg/hostname=$HOSTNAME netcfg/domain=$DOMAIN interface=$INTERFACE_DEV netcfg/disable_dhcp=true netcfg/get_ipaddress=$INTERFACE_IP netcfg/get_netmask=$INTERFACE_NETMASK netcfg/get_gateway=$INTERFACE_GATEWAY netcfg/get_nameservers=$INTERFACE_NAMESERVERS #g" $PROJECTPATH/ubuntu-overssh-iso/txt.cfg
|
||||
|
||||
cp $PROJECTPATH/ubuntu-overssh-iso/preseed.cfg $PROJECTPATH/preseed.cfg
|
||||
#cp $PROJECTPATH/ubuntu-overssh-iso/preseed.cfg $PROJECTPATH/preseed.cfg
|
||||
|
||||
mkisofs -D -r -V UBUNTU_SERVER -cache-inodes -J -l -b isolinux.bin -c boot.cat -no-emul-boot -boot-load-size 4 -boot-info-table -o $PROJECTPATH/ubuntu-overssh-reinstall.iso $PROJECTPATH/ubuntu-overssh-iso
|
||||
|
||||
|
|
14
grub.sh
14
grub.sh
|
@ -78,10 +78,10 @@ sed -i "s/GRUB_DEFAULT=0/GRUB_DEFAULT='$BOOTABLEGRUBNAME'/g" /etc/default/grub
|
|||
|
||||
update-grub
|
||||
|
||||
echo "1. Upload 'preseed.cfg' file for $PRESEED_URL"
|
||||
echo " ==================================== "
|
||||
cat $PROJECTPATH/preseed.cfg
|
||||
echo " ==================================== "
|
||||
echo "2. Reboot current machine and wait to init to ssh installer"
|
||||
echo "3. Connect using ssh client ssh installer@$INTERFACE_IP"
|
||||
echo "4. Your password is $PASSWORD"
|
||||
#echo "1. Upload 'preseed.cfg' file for $PRESEED_URL"
|
||||
#echo " ==================================== "
|
||||
#cat $PROJECTPATH/preseed.cfg
|
||||
#echo " ==================================== "
|
||||
echo "1. Reboot current machine and wait to init to ssh installer"
|
||||
echo "2. Connect using ssh client ssh installer@$INTERFACE_IP"
|
||||
echo "3. Your password is $PASSWORD"
|
||||
|
|
Loading…
Reference in New Issue
Block a user