move helper scripts in scripts dir [ci skip]

This commit is contained in:
Viktor Barzin 2025-10-11 17:12:02 +00:00
parent 51a94faff4
commit 8da88f9f6d
18 changed files with 66 additions and 224 deletions

12
scripts/kill_ns.sh Executable file
View file

@ -0,0 +1,12 @@
#!/usr/bin/env bash
set -e
NAMESPACE=$1
if [ -z "$NAMESPACE" ]; then
echo "Pass in parameter namespace"
exit 1
fi
kubectl proxy &
kubectl get namespace $NAMESPACE -o json |jq '.spec = {"finalizers":[]}' > /tmp/kill_rogue_ns.json
curl -k -H "Content-Type: application/json" -X PUT --data-binary @/tmp/kill_rogue_ns.json 127.0.0.1:8001/api/v1/namespaces/$NAMESPACE/finalize
kill %1