prashant If you're using a static build of a NextJS app then you can host it here with a Nginx static-only app, eg:
- Create a static app and add it to a site.
- Build your NextJS static site, eg
next build && next export.
- Upload the static files to the directory for the app you created in step 1.
- The app should now be served from the site you set up in step 1.
If you're running a NextJS app with server-side rendering then:
- Create a proxy-port app and add it to a site. Make a note of the app's port assignment.
- SSH to your app's shell user and run
npx create-next-app inside of your app directory to install NextJS.
package.json to set your app's port, for example (replace NNNNN with your port assignment):
"dev": "next dev -p NNNNN",
"build": "next build",
"start": "next start -p NNNNN"
- You can then run the app in dev mode with
npm run dev or production with
npm start and it will be served from the site you set up in step 1.