5
0
Fork 0
wa_public_init_repo/guided_setup.sh

59 lines
1.5 KiB
Bash

#!/usr/bin/bash
sudo apt update
sudo apt dist-upgrade -y
sudo apt install -y lvm2 zsh cloud-utils xfsprogs jq hstr ufw git
sudo apt install -y software-properties-common rsync gpg git gnupg2 sudo apt-transport-https
sudo apt install -y sudo curl qemu-guest-agent man-db
sudo apt install -y iftop nload bmon slurm tcptrack htop
sudo apt install nfs-common
sudo systemctl enable qemu-guest-agent #allows Proxmox to look into VM Networking
sudo systemctl start qemu-guest-agent
mkdir -p $HOME/.ssh
function what_to_do() {
echo -ne "
MAIN MENU
1) Install K8s
2) Install NFS Server
0) Exit
Choose an option: "
read -r ans
case $ans in
1)
echo "<=><=><=><=><=><=><=><=><=><=><=><=><=><=><=><=>"
echo "initializing K8s Master Set-Up"
source <(curl -sk https://git.service.wiseadvice.eu/wiseadvice_public_repos/wa_public_init_repo/raw/branch/main/initk8s.sh)
;;
2)
echo "<=><=><=><=><=><=><=><=><=><=><=><=><=><=><=><=>"
echo "initializing K8s Worker Set-Up"
source <(curl -sk https://git.service.wiseadvice.eu/wiseadvice_public_repos/wa_public_init_repo/raw/branch/main/init_nfs_server.sh)
;;
0)
echo "Bye bye."
exit 0
;;
*)
echo "Wrong option."
what_to_do
;;
esac
}
what_to_do
cat <<EOT
# add
GRUB_CMDLINE_LINUX_DEFAULT="quiet rootdelay=5"
GRUB_CMDLINE_LINUX="net.ifnames=0 biosdevname=0 rootdelay=5"
# and do
# sudo grub-mkconfig -o /boot/grub/grub.cfg
EOT
sudo nano /etc/default/grub