> Create a new AWS Instance named “Minikube” on T2-Medium & access it via PUTTY as we do, then do the rest lab:
ubuntu
sudo su
apt update && apt -y install [docker.io](<http://docker.io>)
→ Now Install docker
curl -LO [<https://storage.googleapis.com/kubern>...](<https://www.youtube.com/redirect?event=video_description&redir_token=QUFFLUhqbTZrdHFlT2pZQlB4OXhLWHRhUDEyX2NBbzZ2QXxBQ3Jtc0tsaC1lQVZsY0JXbnVzRGxvWjBjV1Rna2NBZlN3a2JPei1uRlloNzRaV3RQUXRrWVpJaE55ZFZ6S3BCaGFXOUx3ejYtXzJDcjdlSWc4MGJVYzBMNjlIanE3OXVZbjQyLVBQTURlRDF2a0pwbmJVV2hrbw&q=https%3A%2F%2Fstorage.googleapis.com%2Fkubernetes-release%2Frelease%2F%24%28curl&v=hV8zi3vdQqk>) -s [<https://storage.googleapis.com/kubern>...](<https://www.youtube.com/redirect?event=video_description&redir_token=QUFFLUhqbXJxa2IwTm5majRfdUdtV3N4VUcyMmF5WFVVUXxBQ3Jtc0trZ1lnRVBZVjk1Sm5QLWo4aVFEaXhfRkZmTzc5OGx3eHpIYWV6bTZtNHNxUkszU2lfUTdnSnk4TG1pSmRxdmRSb2RlQmlTdGZoVWRrcHJieVd4X3ltQkdJOUcyUkNnZEtLd0daQ194WnM5UWQtek10dw&q=https%3A%2F%2Fstorage.googleapis.com%2Fkubernetes-release%2Frelease%2Fstable.txt%29%2Fbin%2Flinux%2Famd64%2Fkubectl&v=hV8zi3vdQqk>) && chmod +x ./kubectl && sudo mv ./kubectl /usr/local/bin/kubectl
→ Now Install Kubectl
which kubectl
kubectl version
curl -Lo minikube [<https://storage.googleapis.com/miniku>...](<https://www.youtube.com/redirect?event=video_description&redir_token=QUFFLUhqazBQTF9JUWpSRVgtVFNLYlMwYWl3UFAwaG9VQXxBQ3Jtc0tscHpZX1Y2Vm15NHpGdC1OajlkcmxJNExIMVV5ak9pNTllTG1xcmc0eDY0WmRYblg2MWFiNDZXSkxWWmJSNEFxVTYycGZZN3BMYjhuTjh5c05XZDVxLTBJQkNqRWZwejg2NXhKdjhUZ3NMQUJGWU5saw&q=https%3A%2F%2Fstorage.googleapis.com%2Fminikube%2Freleases%2Flatest%2Fminikube-linux-amd64&v=hV8zi3vdQqk>) && chmod +x minikube && sudo mv minikube /usr/local/bin/
→ Now Install Minikube
apt install conntrack
minikube start --vm-driver=none
→ This command starts Minikube [ Always run this to start Minikube ]
minikube status
vi job.yml
→ Open the vi
text editor to create or edit a YAML file named “job.yml”
# JOB
apiVersion: batch/v1
kind: Job
metadata:
name: testjob
spec:
template:
metadata:
name: testjob
spec:
containers:
- name: counter
image: centos:7
command: ["bin/bash", "-c", "echo Technical-Guftgu; sleep 5"]
restartPolicy: Never
kubectl apply -f job.yml
→ Apply the job configuration defined in “job.yml” to create the job in the Kubernetes cluster
kubectl get pods
→ List all pods in the current namespace
watch !!
→ Re-run the last command (kubectl get pods
) continuously to monitor the status of the pods