I accidentally deleted the config file from ~/.kube/config. Every kubectl command fails due to config missing.
Example:
kubectl get nodes
The connection to the server localhost:8080 was refused - did you specify the right host or port?
I have already install k3s using:
export K3S_KUBECONFIG_MODE="644"
curl -sfL https://get.k3s.io | sh -s - --docker
and kubectl using:
snap install kubectl --classic
Does anyone know how to fix this?