Last active
October 24, 2024 10:39
-
-
Save sudhirpandey/e2d469dc9046fb895e9df2172c1ec348 to your computer and use it in GitHub Desktop.
EKS tips
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
kubectl get deployments.apps -o name | xargs -I {} kubectl patch {} --patch "$(cat patch.yml)" | |
kubectl get nodes --no-headers | awk '{print $1}' | xargs -I {} sh -c 'echo {}; kubectl describe node {} | grep Allocated -A 5 | grep -ve Event -ve Allocated -ve percent -ve -- ; echo' | |
kubectl describe daemonset aws-node --namespace kube-system | grep Image | cut -d "/" -f 2 ( to find out the cni) | |
kubectl run busybox --restart=Never --image=busybox:1.28 -- sleep 3600 | |
kubectl exec busybox -- nslookup google.com | |
kubectl config set-context $(kubectl config current-context) --namespace=myapp-dev | |
kubectl run ubuntu --restart=Never --image=mcr.microsoft.com/aks/fundamental/base-ubuntu:v0.0.11 -- sleep 3600 | |
kubectl run debug --restart=Never --image=ghcr.io/sudhirpandey/netshoot:latest -- sleep 3600 | |
kubectl get secrets webui-certificate --template='{{index .data "tls.crt"}}'|base64 -d >/tmp/cert | |
kubectl debug pod -it --image=mcr.microsoft.com/aks/fundamental/base-ubuntu:v0.0.11 | |
#az cli login in pod | |
az login --federated-token "$(cat $AZURE_FEDERATED_TOKEN_FILE)" --service-principal -u $AZURE_CLIENT_ID -t $AZURE_TENANT_ID --allow-no-subscription |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment