WORKKKKKKKS ; Page loading works really well now. If anything goes wrong revert to this commit
This commit is contained in:
32
start_pm2.sh
Executable file
32
start_pm2.sh
Executable file
@@ -0,0 +1,32 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Check the command line argument
|
||||
case "$1" in
|
||||
autodeploy)
|
||||
echo "Starting PM2 with auto-deployment..."
|
||||
pm2 start pm2.config.js
|
||||
;;
|
||||
prod)
|
||||
echo "Starting PM2 with production build..."
|
||||
NODE_ENV=production pm2 start pm2.config.js
|
||||
;;
|
||||
stop)
|
||||
echo "Stopping PM2 process..."
|
||||
pm2 stop all
|
||||
;;
|
||||
restart)
|
||||
echo "Restarting PM2 process..."
|
||||
pm2 restart all
|
||||
;;
|
||||
status)
|
||||
echo "Showing PM2 process status..."
|
||||
pm2 status
|
||||
;;
|
||||
logs)
|
||||
echo "Showing PM2 logs..."
|
||||
pm2 logs
|
||||
;;
|
||||
*)
|
||||
echo "Usage: ./start_pm2 {autodeploy|prod|stop|restart|status|logs}"
|
||||
;;
|
||||
esac
|
||||
Reference in New Issue
Block a user