Syntax: 1kubectl exec --stdin --tty <pod_name> -- /bin/bash Example, with the following pods 1me@example:~$ kubectl get pod 2NAME READY STATUS RESTARTS AGE 3cert-manager-cainjector-68c88cc858-c2rhx 1/1 Running 0 109m 4cert-manager-d76d644df-pgqn9 1/1 Running 0 109m 5cert-manager-webhook-6dd68c6fbc-rzcln 1/1 …
Read MoreA Helm Repo that's in https://github.com/codecentric/helm-charts has a corresponding repo URL. Add it as follows: 1user@example:~$ helm repo add codecentric https://codecentric.github.io/helm-charts 2"codecentric" has been added to your repositories
Read MoreIf you have more than one cluster as illustrated in https://ismael.casimpan.com/quicktasks-k8s/list-nodes-in-kubernetes/, you can change it using command: 1kubectl config use-context <cluster_name_here> Use this command to verify the change: 1kubectl config get-contexts
Read More1user@example:~$ kubectl get pvc --all-namespaces 2NAMESPACE NAME STATUS VOLUME CAPACITY ACCESS MODES STORAGECLASS AGE 3testing-icasimpan-com vol-mysql-mysql-0 Bound pvc-bd199911-e0e5-4327-885d-4902a599ebe2 10Gi RWO do-block-storage 12m
Read MoreIf you have a lot of kubernetes cluster, you will see the following: 1user@example:~$ kubectl config get-contexts 2CURRENT NAME CLUSTER AUTHINFO NAMESPACE 3* do-nyc1-kubernetes-tutorial do-nyc1-kubernetes-tutorial do-nyc1-kubernetes-tutorial-admin 4do-nyc3-infra do-nyc3-infra do-nyc3-infra-admin 5do-nyc2-devinfra …
Read More1user@example:~$ kubectl get nodes 2NAME STATUS ROLES AGE VERSION 3pool-78osxtl1e3-3f4qg Ready <none> 72m v1.17.5 4pool-78osxtl1e3-3f4qw Ready <none> 71m v1.17.5
Read MoreSay you want install jenkins and corresponding repo already added. 1user@example:~$ helm install jenkins codecentric/jenkins 2NAME: jenkins 3LAST DEPLOYED: Sun Jun 28 09:59:52 2020 4NAMESPACE: default 5STATUS: deployed 6REVISION: 1 7TEST SUITE: None 8NOTES: …
Read MoreWhen you see similar error as below: 1user@example:~$ kubectl get nodes 2The connection to the server localhost:8080 was refused - did you specify the right host or port? Check for the "$KUBECONFIG" if set and "kubectl config view" output. Chances are, both are empty like below: 1user@example:~$ …
Read More