This file contains 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
#!/usr/bin/env bash | |
branch_name=`git symbolic-ref --short HEAD` | |
retcode=$? | |
non_push_suffix="_local" | |
# Only push if branch_name was found (my be empty if in detached head state) | |
if [ $retcode = 0 ] ; then | |
#Only push if branch_name does not end with the non-push suffix |
This file contains 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 po -a --all-namespaces -o json | jq '.items[] | select(.status.reason!=null) | select(.status.reason | contains("Evicted")) | "kubectl delete po \(.metadata.name) -n \(.metadata.namespace)"' | xargs -n 1 bash -c |
OlderNewer