NextJS deployed to AWS Amplify with ISR - build takes too long

Viewed 567

By default, while deploying the NextJS app to AWS Amplify, it uses 7GB RAM. When I build my app on EC2 instance with 2GB RAM (1vCPU), building app takes less than a minute, whereas, when the app builds on AWS Amplify, it takes a few minutes. Is there a way to analyze why this happens and reduce the time AWS Amplify takes to build?

By build time, I am not including the time for provisioning or other tasks. I am talking about build time only.

1 Answers
Related