Kubernetes Tutorial
Reference:
Link:-
Annotations:
https://kubernetes.io/docs/reference/glossary/?all=true#term-annotation
Kubernetes Fundamentals
- Chapter 1. Course Introduction
- Chapter 2. Basics of Kubernetes
- Chapter 3. Kubernetes Architecture
- Chapter 4. Installation and Configuration
- Chapter 6. API Objects
- Chapter 7. Managing State with Deployments
- Chapter 8. Services
- Chapter 9. Volumes and Data
- Chapter 10. Ingress
- Chapter 11. Scheduling
- Chapter 12. Logging and Troubleshooting
- Chapter 13. Custom Resource Definitions
- Chapter 14. Kubernetes Federations
- Chapter 15. Helm
- Chapter 16. Security
What is Kubernetes?
Kubernetes is an open-source system for automating deployment, scaling, and management of containerised applications.
Kubernetes ("k8s" for short), was a project originally started at, and designed by Google, and is heavily influenced by Google's large scale cluster management system
simply, k8s gives you a platform for managing and running your applications at scale across multiple physically (or virtual) machines.
Installing Minikube and Kubectl
To make things easy, we're going to use minikube on our local machine to run a single-node kubernetes cluster. Minikube is a handy tool that starts a virtual machine and bootstraps the cluster for you
Firstly, if you don't have VirtualBox, go download and install it. While minikube works with other virtualisation platforms, Ive found VirtualBox to be the most reliable.
Next, we need to install not only minikube, but also kubectl which will be used to interact with our k8s cluster. To do so, run the script below:
Next, we need to install not only minikube, but also kubectl which will be used to interact with our k8s cluster. To do so, run the script below:
#!/bin/bash
ARCH=$(uname | awk '{print tolower($0)}')
TARGET_VERSION="v0.15.0"
MINIKUBE_URL="https://storage.googleapis.com/minikube/releases/${TARGET_VERSION}/minikube-${ARCH}-amd64"
KUBECTL_VER="v1.5.1"
KUBECTL_URL="http://storage.googleapis.com/kubernetes-release/release/${KUBECTL_VER}/bin/${ARCH}/amd64/kubectl"
echo "installing latest kubectl..."
curl -Lo kubectl $KUBECTL_URL && chmod +x kubectl && sudo mv kubectl /usr/local/bin/
echo "installing latest minikube..."
curl -Lo minikube $MINIKUBE_URL && chmod +x minikube && sudo mv minikube /usr/local/bin/
ISO_URL="https://storage.googleapis.com/minikube/iso/minikube-v1.0.1.iso"
minikube start \
--vm-driver=virtualbox \
--iso-url=$ISO_URL
echo "starting minikube dashboard..."
minikube dashboard
If everything has worked correctly, the kubernetes dashboard should open in your browser.
Using kubectl
When minikube starts, it will automatically set the context for kubectl. If you run
kubectl get nodes
you should see something like this:
kubectl get nodes
NAME STATUS AGE
minikube Ready 2m
kubectl get nodes
NAME STATUS AGE
minikube Ready 2m
Same with if you run
kubectl get pods --all-namespaces
:kubectl get pods --all-namespaces
NAMESPACE NAME READY STATUS RESTARTS AGE
kube-system kube-addon-manager-minikube 1/1 Running 0 3m
kube-system kube-dns-v20-qkzgg 3/3 Running 0 3m
kube-system kubernetes-dashboard-1hs02 1/1 Running 0 3m
While the dashboard is useful for visualising pods and deployments, we'll primarily be using kubectl to interact with our cluster.
Your blog is in a convincing manner, thanks for sharing such an information with lots of your effort and time
ReplyDeleteKubernetes online training
Kubernetes certification training
Kubernetes training
Kubernetes course