<!-- SPDX-FileCopyrightText: 2022 eclipse foundation SPDX-License-Identifier: EPL-2.0 -→
Force Delete a Kubernetes Namespace
NAMESPACE=grac-eclipsefdn-it-releng-gitlab-runner-as-code
kubectl get namespace $NAMESPACE -o json|sed 's/"kubernetes"//' > /tmp/tmp.json
Delete finalizers kubernetes
from namespace definition.
"spec": {
"finalizers": [
]
},
Apply modification :
kubectl proxy
curl -k -H "Content-Type: application/json" -X PUT --data-binary @tmp.json http://127.0.0.1:8001/api/v1/namespaces/$NAMESPACE/finalize