Skip to content

Conversation

@sashko9807
Copy link
Member

This pull request updates the Dockerfile to optimize the build process and improve the runtime configuration for a Next.js application. The most important changes include switching to a standalone server setup, refining how static assets are handled, and updating the application startup command.

Dockerfile improvements:

  • Standalone server setup: Replaced the copying of multiple configuration files and the entire .next directory with only the standalone server and its dependencies (/app/.next/standalone) and static assets (/app/.next/static). This simplifies the deployment and reduces the image size.
  • Updated startup command: Changed the CMD instruction from running npm run start to directly executing node server.js, aligning with the standalone server setup.
  • Environment variable format: Adjusted the ENV PORT declaration to use PORT=3040 for consistency.

@sashko9807 sashko9807 added the run tests Allows running the tests workflows for forked repos label Aug 1, 2025
@github-actions
Copy link

github-actions bot commented Aug 1, 2025

✅ Tests will run for this PR. Once they succeed it can be merged.

@github-actions github-actions bot removed the run tests Allows running the tests workflows for forked repos label Aug 1, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant