diff --git a/CreaCluster/10-prepara.sh b/CreaCluster/10-prepara.sh new file mode 100644 index 00000000..03910748 --- /dev/null +++ b/CreaCluster/10-prepara.sh @@ -0,0 +1,84 @@ +read -p "Voy a quitar swap. Pulsa ENTER para seguir:" mainmenuinput + +# disable swap + +sudo swapoff -a +sudo sed -i '/ swap / s/^\(.*\)$/#\1/g' /etc/fstab + +read -p "Cargar kernel modules. Pulsa ENTER para seguir:" mainmenuinput + +# Load the following kernel modules on all the nodes + +sudo tee /etc/modules-load.d/containerd.conf </dev/null 2>&1 +sudo sed -i 's/SystemdCgroup \= false/SystemdCgroup \= true/g' /etc/containerd/config.toml + +read -p "Enable containerd. Pulsa ENTER para seguir:" mainmenuinput + +# Restart and enable containerd service + +sudo systemctl restart containerd +sudo systemctl enable containerd + +read -p "AƱade repository de Kubernetes. Pulsa ENTER para seguir:" mainmenuinput + +# Add apt repository for Kubernetes + +curl -s https://packages.cloud.google.com/apt/doc/apt-key.gpg | sudo apt-key add - +sudo apt-add-repository "deb http://apt.kubernetes.io/ kubernetes-xenial main" + +# Install Kubernetes components Kubectl, kubeadm & kubelet +read -p "Instalar componentes de kubernetes. Pulsa ENTER para seguir:" mainmenuinput + + +sudo apt update +sudo apt install -y kubelet kubeadm kubectl +sudo apt-mark hold kubelet kubeadm kubectl diff --git a/CreaCluster/00-borraCluster.sh b/CreaCluster/20-borraCluster.sh similarity index 100% rename from CreaCluster/00-borraCluster.sh rename to CreaCluster/20-borraCluster.sh diff --git a/CreaCluster/01-inicializaCluster.sh b/CreaCluster/30-inicializaCluster.sh similarity index 100% rename from CreaCluster/01-inicializaCluster.sh rename to CreaCluster/30-inicializaCluster.sh diff --git a/CreaCluster/02-creaConfigCluster.sh b/CreaCluster/40-creaConfigCluster.sh similarity index 100% rename from CreaCluster/02-creaConfigCluster.sh rename to CreaCluster/40-creaConfigCluster.sh diff --git a/CreaCluster/03-creaCalico.sh b/CreaCluster/50-creaCalico.sh similarity index 100% rename from CreaCluster/03-creaCalico.sh rename to CreaCluster/50-creaCalico.sh diff --git a/CreaCluster/04-masterEsWorker.sh b/CreaCluster/60-masterEsWorker.sh similarity index 100% rename from CreaCluster/04-masterEsWorker.sh rename to CreaCluster/60-masterEsWorker.sh diff --git a/CreaCluster/05-confirmaRunning.sh b/CreaCluster/70-confirmaRunning.sh similarity index 100% rename from CreaCluster/05-confirmaRunning.sh rename to CreaCluster/70-confirmaRunning.sh diff --git a/CreaCluster/shell.sh b/CreaCluster/shell.sh new file mode 100644 index 00000000..44ded62a --- /dev/null +++ b/CreaCluster/shell.sh @@ -0,0 +1 @@ +read -p "Pulsa ENTER para seguir:" mainmenuinput