I've just created a new app from the Next.js starter and added a page with some server-side data fetching (SSR).
Build and deployment are running successfully. Amplify detects the framework correct with "Next.js SSR". Also the Lambda@Edge exists after the deployment. But there is no trigger connected as far as I can see.
But when I navigate to the SSR Page in the browser I always receive a "503 ERROR
The request could not be satisfied."
After some investigation I found out that I have to set webpack to version 4 in my next.config.js.
The latest Next.js uses webpack 5 as default which is not working with AWS Amplify Hosting right now.
Great article, thanks!
I've just created a new app from the Next.js starter and added a page with some server-side data fetching (SSR).
Build and deployment are running successfully. Amplify detects the framework correct with "Next.js SSR". Also the Lambda@Edge exists after the deployment. But there is no trigger connected as far as I can see.
But when I navigate to the SSR Page in the browser I always receive a "503 ERROR
The request could not be satisfied."
Maybe anyone got an idea?
Hey, thanks for bubbling this up! The engineering team is checking into it and I'll let you know when I hear back!
After some investigation I found out that I have to set webpack to version 4 in my next.config.js.
The latest Next.js uses webpack 5 as default which is not working with AWS Amplify Hosting right now.
Yes, you're right. Downgrading Next.js to v11.1.3 and setting
webpack5: false
in next.config.js fixed the issue.github.com/aws-amplify/amplify-hos...