Hi all, I am facing issue while deploying Gatsby SSR code to GCP using docker as an image container.
The image size is coming more than 3.0GB which is heavy for handling load and autoscaling in GCP.
Right now using single stage build in Docker
Where building the application first using Gatsby build and then serving it on a port using Gatsby serve command.
Because node modules are also part of the image so size is very high.
Tried nginx multi-stage build as well but that didn't work because it is not able to find the index.html in the root of the build folder.
This is another issue index.html is not getting generated after running Gatsby build in my Gatsby SSR application
Please help me reduce the image size at most priority.
Latest comments (1)
Here are some things you can do to reduce the image size of your Gatsby SSR application:
Here are some additional things you can do to troubleshoot the issue with the index.html file not being generated:
If you still have further queries, do post it in forums.docker.com
you can also refer to docker.com/blog/9-tips-for-contain...