第一次部署应用到服务器上,写这篇文章来记录一下基本的流程,以方便以后忘了可以查看,并希望可以帮到同样有疑惑的朋友。
环境
操作系统: Ubuntu 16.04
腾讯云主机镜像: CentOS 7.2 64位
登录云主机
参考链接: 帮助中心-腾讯云 如何远程登录linux服务器
使用ssh远程登录,也可以用其他的登录,自行选择。
* 连接: ssh -q -l [云服务器登录账号] -p 22 [云服务器的公网IP地址]
* 断开连接: logout 或 exit
Node.js安装
根据需要的版本分别输入:
* Run as root on RHEL, CentOS or Fedora, for Node.js v6 LTS:
curl –silent –location https://rpm.nodesource.com/setup_6.x | bash -
- Alternatively for Node.js v7:
curl –silent –location https://rpm.nodesource.com/setup_7.x | bash -
- Alternatively for Node.js 0.10: </