Deployment

I think is not that it is not running, but answering http when https is expected. Look this part of the log:

server gave HTTP response to HTTPS client

You can probably circumvent this by using dockerhub, quay or similar until you get you registry/pod configuration working fine :slight_smile:

I have created a small springboot application and tried to deploy on kubernetes, I have assigned two pods for it. One pod is running fine on the Master (named it kmaster) but I am getting an error - ImagePullBackOff - on the Node (kNode).

Any idea why the same application is running fine on one pod while giving an error on the other pod?

If you run kubectl describe pod, can you verify you are using the same container image?

Also, in the describe look at the extended error for the image pull. Why does it fail?

Does the node have internet connection?

Yes, the node have internet connection.

In the describe command of a pod, I am getting the following error message - http: server gave HTTP response to HTTPS client

I googled this error and found that the docker registry need to be made insecure in order to resolve this error. So I have tried to make the docker registry as insecure but the error is still coming. Any insights on this error on how to resolve this?

Okay, that is totally different. In any case, I suspect maybe you are not running the same on different nodes (like, the pod started before some change to the registry, the image was pulled manually in the node in some other way, etc.)

The error seems clear that the node is requesting https bit seeing http in return, right?

Not sure until which degree you can configure that (maybe kubelet has flags, on my phone can’t check easily).

Are you sure you don’t want https?

Another workaround will be using a managed docker registry or trying to do docker pull manually in the node so the image is there and doesn’t need to download (if you can convince docker to download that image, of course :)).

Would any of that work?

I am facing an issue in Kubernetes where I have deployed docker image (created with Springboot application and postgres). I was able to run successfully this image in docker but when I have deployed this image in kubernetes, the service is not coming up. Even though the pods run for a while but errored out.

Any suggestion on why the same docker image is not running on kubernetes?