- Newest
- Most votes
- Most comments
AWS Amplify Hosting has recently extended its support for server-side rendering (SSR) applications, including Nuxt.js. However, it's important to note that the current support is primarily focused on Nuxt 3, which uses the Nitro server.
For your Nuxt 2 SSR projects, you may face some challenges when trying to deploy them on Amplify Hosting. The zero-configuration deployment that works seamlessly with Nuxt 3 is not available for Nuxt 2 SSR applications.
To deploy your Nuxt 2 SSR projects on Amplify, you might need to make some adjustments:
-
Ensure you're using the latest version of Amplify Hosting that supports SSR for various frameworks.
-
You may need to modify your build configuration to properly generate the SSR output. The
.amplify-hostingdirectory you're using in yourbaseDirectoryis correct for the new SSR deployment specification. -
Your
buildcommand might need to be adjusted to generate the correct SSR output for Amplify Hosting. Instead of justyarn build, you might need a command that specifically builds for SSR and organizes the output according to Amplify's new deployment specification. -
You may need to create a custom server file that Amplify can use to serve your Nuxt 2 SSR application.
-
Ensure your
nuxt.config.jsfile is properly configured for SSR deployment.
If you continue to face issues, you might want to consider upgrading your projects to Nuxt 3, which has built-in support for deployment on Amplify Hosting via the Nitro server adapter.
Alternatively, you could explore using AWS Elastic Beanstalk or Amazon EC2 for hosting your Nuxt 2 SSR applications, as these services offer more flexibility in terms of server configuration.
Remember, Amplify Hosting's extended SSR support is still relatively new, and the ecosystem is evolving. Keep an eye on Amplify documentation and community resources for any updates or specific guidance for Nuxt 2 SSR deployments.
Sources
Introducing Support for Hosting Any SSR app on AWS Amplify Hosting | Front-End Web & Mobile
AWS Amplify Hosting extends server-side rendering (SSR) support to additional frameworks
Relevant content
- asked 4 years ago
- asked 5 months ago
- AWS OFFICIALUpdated 4 years ago
- AWS OFFICIALUpdated 8 months ago
