Centos7 安装Node.js10以上版本的方法步骤

356 阅读1分钟

安装node

1- 最新发布:

$ yum clean all && yum makecache fast
$ yum install -y gcc-c++ make
$ curl -sL https://rpm.nodesource.com/setup_12.x | sudo -E bash -

2- 稳定发布:

$ yum clean all && yum makecache fast
$ yum install -y gcc-c++ make
$ curl -sL https://rpm.nodesource.com/setup_10.x | sudo -E bash -

检查Node.js和NPM版本

$ node -v 
// v12.3.1