CentOS安装Node.js

原文地址:https://nodejs.org/en/download/package-manager/#enterprise-linux-and-fedora


下面是部分有用的信息:

Run as root on RHEL, CentOS or Fedora, for Node.js v4 LTS Argon:

curl --silent --location https://rpm.nodesource.com/setup_4.x | bash -

Alternatively for Node.js v5:

curl --silent --location https://rpm.nodesource.com/setup_5.x | bash -

Alternatively for Node.js 0.10:

curl --silent --location https://rpm.nodesource.com/setup | bash -

Then install, as root:

yum -y install nodejs

Optional: install build tools

To compile and install native addons from npm you may also need to install build tools:

yum install gcc-c++ make# or: yum groupinstall 'Development Tools'



你可能感兴趣的:(centos,node.js)