PM2 init scripts Edit the init scripts for the three environments: Edit the project name Edit the project dir (should be /opt/PROJECT_NAME) Edit logfile and pidfile names Set your node.js script name Set the correct NODE_ENV and other env variables