Latest doc – https://github.com/certifications-tutorials/kubernetes-cluster-setup
Following commands would help you to create 1 Master and 1 Node in same VM.
Run Following commands in Master Node
$ sudo -s
$ cd
$ git clone https://github.com/certifications-tutorials/cks-course-environment/
$ cd cks-course-environment/
$ cd cluster-setup/
$ cd latest/
$ chmod 755 install_master.sh
$ ./install_master.sh
$ kubectl get nodes
$ kubectl taint nodes --all node-role.kubernetes.io/master-
or
kubectl taint nodes ip-172-31-12-228 node-role.kubernetes.io/control-plane:NoSchedule-
$ kubectl cluster-info
Code language: JavaScript (javascript)
Run following commands in Worker Node
$ git clone https://github.com/certifications-tutorials/cks-course-environment/
$ cd cks-course-environment/
$ cd cluster-setup/
$ ls
$ cd latest/
$ ls
$ chmod 755 install_worker.sh
$ ./install_worker.sh
$ kubeadm join 172.31.12.163:6443 --token 22zff9.qls775ypsmn3jtkg --discovery-token-ca-cert-hash sha256:c2df87a631d2a715ca926c4247c7f51699a652a13973c1149573561d87cd26b4
Code language: PHP (php)
Sample Code – https://github.com/certifications-tutorials/cks-course-environment/
How to download using git
$ git clone https://github.com/certifications-tutorials/cks-course-environment/
# cks-master
sudo -i
bash <(curl -s https://raw.githubusercontent.com/certifications-tutorials/cks-course-environment/master/cluster-setup/latest/install_master.sh)
# cks-worker
sudo -i
bash <(curl -s https://raw.githubusercontent.com/certifications-tutorials/cks-course-environment/master/cluster-setup/latest/install_worker.sh)
# run the printed kubeadm-join-command from the master on the worker
Code language: PHP (php)
I’m Rajesh Kumar, a DevOps, SRE, DevSecOps, Cloud, and Platform Engineering expert passionate about sharing practical knowledge, real-world experiences, and industry best practices. I have worked at Cotocus and regularly write about technology, travel, investing, health, product reviews, and digital marketing through my various platforms.
I publish technical articles at DevOps School, travel stories at Holiday Landmark, stock market insights at Stocks Mantra, health and fitness guidance at My Medic Plus, product reviews at TrueReviewNow, and SEO and digital marketing strategies at Wizbrand.
Find Trusted Cardiac Hospitals
Compare heart hospitals by city and services โ all in one place.
Explore Hospitals