Skip to content

Latest commit

 

History

History
30 lines (21 loc) · 776 Bytes

kubernetes-cli.md

File metadata and controls

30 lines (21 loc) · 776 Bytes

Get all cert-manager resources

kubectl get Issuers,ClusterIssuers,Certificates,CertificateRequests,Orders,Challenges --all-namespaces

Reset Kubeadm cluster

kubeadm reset

Get Kubernetes Node Taints

kubectl describe node <nodename> | grep -i taints

Portforwarding from Kubernetes to localhost

kubectl port-forward -n <namespace> <service> <localport>:<remoteport>
kubectl port-forward -n monitoring svc/lma-kube-prometheus-stack-prometheus 8080:9090

Get Namespace, Pod, and in-use Container Images Mapped Together

kubectl get pods --all-namespaces -o json | jq -r '.items[] | select(.status.phase == "Running") | .metadata.namespace + " " + .metadata.name + " " + .spec.containers[].image'