Installing Node.js
Before you can deploy your app on the production server, you need to install Node.js. Here's how you can do that:
Debian, Ubuntu |
Run the following commands to install Node.js from the NodeSource APT repository. With these commands, we also install a compiler so that we are able to install native addons from npm. $ sudo apt-get update $ sudo apt-get install -y curl apt-transport-https ca-certificates && curl --fail -ssL -o setup-nodejs https://deb.nodesource.com/setup_6.x && sudo bash setup-nodejs && sudo apt-get install -y nodejs build-essential |
Red Hat, CentOS, Fedora |
Run the following commands to enable EPEL and to install Node.js from the NodeSource YUM repository. With these commands, we also install a compiler so that we are able to install native addons from npm. $ sudo yum install -y epel-release curl $ curl --fail -sSL -o setup-nodejs https://rpm.nodesource.com/setup_6.x $ sudo bash setup-nodejs $ sudo yum install -y nodejs gcc-c++ make |
Gentoo |
$ sudo emerge nodejs
|
Arch Linux |
$ sudo pacman -S nodejs npm
|
macOS | Please download the Node.js macOS installer from the Node.js download page and run it. |
Other Linux operating systems (32-bit or 64-bit only) | Please download either the 32-bit or 64-bit Node.js Linux binaries from the Node.js download page. |
Other operating systems | Please install Node.js from source from www.nodejs.org. |
When you are done, continue to the next step.
Continue: Install Passenger »