Running the app

How to run JayCP on an Ubuntu server.

Once the app and the database is connected, you need to build the app by running the following command in the terminal:

npm run build

Once the app is built, you can run it by running the following command in the terminal:

pm2 start npm -- start

This will start the app on port 3000. If you want to run the app on a different port, you can change this in the package.json file.

Find the following line in the package.json file:

"start": "next start -p 3000"

Change the number after the -p option to the new port number you would like to run the app.

Stopping the app

To stop the app, you can run the following command in the terminal:

pm2 stop npm