I have a project that I build using Next Js, Cloudflare, and Docker. There’s nothing wrong from the backend and I can get all the data of the products. But the time to serve all image from the response took around 12 seconds which is too long. I can’t even access the same page twice because I’ll get error response of bad gateway. I use next built in tag Image. I try to check if my project shutdown in my Virtual Private Server (VPS) but it still alive. I check the docker logs for my images and there’s nothing wrong in the logs. Why this is happen and how to speed up the image serve?
When i try to reload or refresh my pages for two times it’ll become normal again.