POD.yaml
apiVersion: v1
kind: Pod
metadata:
name: hello-world
spec:
containers:
- name: hello-world
image: gcr.io/google-samples/hello-app:1.0
ssh aen@c1-master1
cd ~/content/course/m2/demos
#Get information about our current context, ensure we're logged into the correct cluster.
kubectl config get-contexts
#Change our context if needed.
kubectl config use-context kubernetes-admin@kubernetes
#Get information about the API Server for our current context, which should be kubernetes-admin@kubernetes
kubectl cluster-info
#Get a list of API Resources available in the cluster
kubectl api-resources | more
#Using kubectl explain
kubectl explain pods | more
#Creating a pod with YAML
kubectl apply -f pod.yaml
#Let's look more closely at what we need in pod.spec and pod.spec.containers
kubectl explain pod.spec | more
kubectl explain pod.spec.containers | more
#Get a list of our currently running pods
kubectl get pod
#Remove our pod
kubectl delete pod hello-world
Kubernetes Tutorials using EKS – Part 1 – Introduction and Architecture
Kubernetes Tutorials using EKS – Part 2 – Architecture with Master and worker
Kubernetes Tutorials using EKS – Part 3 – Architecture with POD – RC – Deploy – Service
Kubernetes Tutorials using EKS – Part 4 – Setup AWS EKS Clustor
Kubernetes Tutorials using EKS – Part 5 – Namespaces and PODs
Kubernetes Tutorials using EKS – Part 6 – ReplicationControllers and Deployment
Kubernetes Tutorials using EKS – Part 7 – Services
Kubernetes Tutorials using EKS – Part 8 – Volume
Kubernetes Tutorials using EKS – Part 9 – Volume
Kubernetes Tutorials using EKS – Part 10 – Helm and Networking
Latest posts by Rajesh Kumar (see all)
- Best Hospitals for affordable surgery for medical tourism - December 20, 2024
- Top Global Medical Tourism Companies in the World - December 20, 2024
- Medical Laboratory equipment manufacturing company - December 20, 2024