1、下载

英文网址:https://nodejs.org/en/download/

 中文网址:http://nodejs.cn/download/

2、 uname -a  命令查看到我的Linux系统位数

x86_64表示64位系统, i686 i386表示32位系统

3、上传,如上传至:/app/software/

4、解压,重命名,重命名不是必须

 ① tar -xvf   node-v6.10.0-linux-x64.tar.xz   

    ② mv node-v6.10.0-linux-x64  nodejs

5、建立软连接,变为全局

①ln -s /app/software/nodejs/bin/npm /usr/local/bin/ 

②ln -s /app/software/nodejs/bin/node /usr/local/bin/

6、检查是否已配置为全局变量

node -v 返回版本号即成功

============================================

部署服务

1、上传并解压

如:server.js

2、启动您的服务

nohup node server.js & 回车

3、查看进程

ps -ef|grep server.js

 

 

相关文章:

  • 2021-10-23
  • 2021-06-07
  • 2022-12-23
  • 2021-11-19
  • 2021-07-15
  • 2021-12-29
猜你喜欢
  • 2021-04-17
  • 2022-02-12
相关资源
相似解决方案