I have two instances one is Kubernetes server and other servers has installed Jenkins. admin.conf file of Kubernetes server transfered to jenkins server and then I tried to connect Kubernetes server from Jenkins server via Kubectl commands like "kubectl --kubeconfig /data/admin.conf get namespaces"
I got follwoing error message
"Unable to connect to the server: x509: certificate signed by unknown authority (possibly because of "crypto/rsa: verification error" while trying to verify candidate authority certificate "kubernetes")"
I also export admin.conf to KUBECONFIG
export KUBECONFIG=/data/admin.conf
But error as the same