Kubectl apply return certificate has expired or is not yet valid

10/3/2017

I m using docker and kubernetes for deployment. When I try to deploy project.yaml file by running kubectl apply -f project.yaml I'm getting an error Unable to connect to the server: x509: certificate has expired or is not yet valid. I found here https://github.com/kubernetes/kubernetes/wiki/Debugging-FAQ that is is clock issue but I don't know how to sync local clock with server one. I tried manuali setting local clock to UK time(Where server is) but it does't work.

-- miso 911
docker
kubernetes

0 Answers