Skip to content

Commit

Permalink
fix: improved error msg.
Browse files Browse the repository at this point in the history
  • Loading branch information
beneiltis committed Feb 28, 2024
1 parent 2e111b0 commit 4041b01
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion utils/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -274,7 +274,7 @@ func GetDefaultKubeConfig() string {
}
// check if file exists in kubeconfig
if _, err := os.Stat(kubeconfig); os.IsNotExist(err) {
logger.Log.Fatalf("$KUBECONFIG is empty and default context cannot be loaded. Please set $KUBECONFIG or use --context flag to proceed.")
logger.Log.Fatalf("Error: $KUBECONFIG is not set, and the default Kubernetes context cannot be loaded. The $KUBECONFIG environment variable specifies the kubeconfig file path, which is essential for connecting to your Kubernetes cluster. To resolve this, please set $KUBECONFIG by using 'kubectx' for easier context switching or by manually specifying the path to your kubeconfig file. For detailed instructions on configuring your kubeconfig, please refer to https://kubernetes.io/docs/concepts/configuration/organize-cluster-access-kubeconfig/.")
}
return kubeconfig
}

0 comments on commit 4041b01

Please sign in to comment.