I am attempting to setup the Kubernets Master node on a Jetson Nano. However, I am stuck at the step where you are supposed to download the flannel YAML. Everytime I get the same error:
Unable to connect to the server: x509: certificate is valid for 10.xx.x.x, 192.xxx.x.xx, not 127.0.0.1
I'm not sure why it is trying to connect to my local host to get the download. So far I have done the following:
sudo kubeadm reset
I would always delete the .kube/ folder in my home directory. Then I run:
sudo kubeadm init --pod-network-cidr=10.244.0.0/16
mkdir -p $HOME/.kube
sudo cp -i /etc/kubernetes/admin.conf $HOME/.kube/config
sudo chown $(id -u):$(id -g) $HOME/.kube/config
All of these commands execute no problem. For the first command I have also tried adding this line, but then I get an error saying it can't verify the certificate:
--apiserver-cert-extra-sans=127.0.0.
1
I have tried two commands to download the YAML file
sudo kubectl apply -f https://raw.githubusercontent.com/coreos/flannel/master/Documentation/kube-flannel.yml
and
curl -sSL https://raw.githubusercontent.com/coreos/flannel/v0.12.0/Documentation/kube-flannel.yml | kubectl apply -f -
In the config file I have added the line
insecure-skip-tls-verify: true
right after the key, but this doesn't work either.
Is there something I am missing or need to change? None of the other solutions have worked.
I have used the following references:
Flannel network failing during Kubernetes installation, please suggest how to fix this
Kubernetes Setting Up Flannel Pod Network
https://github.com/kubernetes/kubernetes/issues/48378
x509 certificate signed by unknown authority- Kubernetes
https://phoenixnap.com/kb/install-kubernetes-on-ubuntu
https://developer.nvidia.com/blog/deploying-ai-apps-with-egx-on-jetson-xavier-nx-microservers/