K8s Multi-Node on Multi-Cloud

Problem Statement:

Solution: First we need to launch instances in AWS, Azure, for provisioning, I am using Terraform.

Prerequisite:

Step-1)Launching Instances in AWS Azure

terraform init
terraform apply

Explanation:

Output

AWS instance launched
Azure VM launched

Note: For configuring k8s Multi-Node Cluster I am using a bash script and make sure you’re login into root accunt

Step-2)Configure K8s Master

bash script.sh

Explanation:

Output

AWS k8s Master

Step-3)Configure Slave Nodes in AWS, Azure.

bash script.sh

Explanation:

kubeadm join VM_PUBLIC_IPv4:6443 --token TOKEN --discovery-token-ca-cert-hash CERT_HASH
kubeadm join VM_PUBLIC_IPv4:6443 --token TOKEN --discovery-token-ca-cert-hash CERT_HASH

Final Output

Source Code

DevOps/Cloud Enthusiast