Warn Users of Region Before Executing kubectl Commands #1727
Labels
kind/feature
Categorizes issue or PR as related to a new feature.
needs-triage
Indicates an issue or PR lacks a `triage/foo` label and requires one.
What would you like to be added:
Currently, kubectl does not provide any warning regarding which Kubernetes cluster or cloud region the command is being executed on. This can lead to accidental modifications in the wrong environment (e.g., production instead of staging or wrong region ).
Add an interactive warning before executing any kubectl apply, delete, patch, replace, taint, exec, create, run commands, displaying the current region and asking for user confirmation before proceeding.
Example :
This ensures users are aware of the region and cluster before proceeding.
Why is this needed:
Prevents accidental changes in production clusters.
Helps users working across multiple environments in difference regions
Enhances safety in cloud-based Kubernetes deployments.
The text was updated successfully, but these errors were encountered: