Kubectl Change Namespace -

kubectl config set-context --current --namespace=my-namespace

To switch to the prod namespace, you can use: kubectl change namespace

To set the current namespace to dev , use: kubectl change namespace

Use Short-Lived Contexts: Avoid staying in the "kube-system" or "production" namespaces longer than necessary. kubectl change namespace