The guide on NextJs with docker project setup on EasyPanel
Visit repository: https://github.com/digitalandyeu/next-with-docker
Source from a github digitalandyeu / next-with-docker repo at the main branch
Chose Dockerfile build method
The above step configuration is enough to start your app, now.
Because the first-deploy.sh script is missing, in our build do manually:
- Stop the app
- Force rebuild
- Press Deploy
- Start the app
Now You should see your app running and available at default domain:
Visit default public domain from Domains section:
Navigate to Enviorment section and paste your enviorment variables
# https://nextjs.org/docs/app/building-your-application/configuring/environment-variables
NEXT_PUBLIC_DOMAIN=next.digitalandy.eu
NEXT_PUBLIC_URL=https://$NEXT_PUBLIC_DOMAIN
PORT=3000Turn on the Create .env file option and save
Navigate to Domains section and
- attach domain, for example
next.digitalandy.euat port3000with https enabled - make your domain primary by clicking the star icon
- remove the default public domain attached by easypanel
Easypanel handles the http -> https redirect + cert & auto renewal for you
- Deployment Trigger url
Copy the Deployment Trigger url value from Deployments section
Deployment Trigger url example: http://11.11.11.11:3000/api/deploy/73xxxx3a
- Configure the repository at GitHub
Click settings -> webhooks -> add new, then follow the below pattern:
Payload URL: Deployment Trigger url
Content Type: application/json
SSL Verification: disable
Event: just push event
Active: checked
Trigger the new deploy, validate if port has changed to the value we provided earlier in .env file








