We recommend that you familiarize yourself with the Node.js documentation
Node.js comes with the following management tools:
- Update path
- Update startup command
- Choose version
- Change mode
- Delete application
To deploy a Node.js app:
- Open Websites in the left side bar
- Select the website you would like to deploy Node to
- When the website dashboard loads select the Advanced drop down in the top navigation, then click Node.js
- Click Deploy app
- Once the form loads, complete the fields:
-
Automatic mode:
- Automatic mode is designed for production use.
- Your application will be started automatically, using your selected Node version.
- If your application exits (regardless of the error code) it will be restarted automatically.
-
Manual mode:
- In manual mode, your application will not be started automatically. It will not be restarted if exits or the website container is restarted.
- To initialise the node environment for manual start, run install_nvm_and_node.sh
-
Proxy settings:
- For your application to be accessible from the internet, you need to enable the proxy
- You should enter the port on which you intend to start your application.You cannot use port numbers <1024 or >65535.
-
Startup command:
- This is the command the control panel will use to start your application. It will normally look something like “npm start –production”.
-
Working directory:
- You should set the directory in which the application expects to run from. This should be relative to your home directory, not an absolute path.
-
Node version:
- You can select from any of the available major versions of Node.js.