当前位置:网站首页>在服务器上运行node流程
在服务器上运行node流程
2022-07-30 00:58:00 【淼清风】
安装ndoe
- 下载
weget node压缩文件地址
- 解压缩
tar -xvf 压缩文件名
- 查看node
cd node文件目录
- 建立软连接
ln -s nodebin文件路径 全局bin文件路径
ln -s npmbin文件路径 全局bin文件路径
运行node
普通运行
node 文件路径
持续运行
- 安装forever
npm install forever -g
- 执行forever命令
forever start 文件路径
- 停止运行
forever stop 文件路径
node进程管理PM2
- 安装2
npm install pm2 -g
- 启动node任务
pm2 start index.js
其他PM2命令
# 重启指定任务,0代表任务的索引
pm2 restart 0
# 重启所有任务
pm2 restart all
# 停止指定任务
pm2 stop 0
# 停止所有任务
pm2 stop all
# 删除指定任务
pm2 delete 0
# 删除所有任务
pm2 delete all
边栏推荐
- 自学HarmonyOS应用开发(47)- 自定义switch组件
- 这是一道非常有争议的题,我的分析如下: TCP/IP在多个层引入了安全机制,其中TLS协议位于______。 A.数据链路层 B.网络层 C.传输层 D.应用层
- FlutterBoost 3.0出现 Activity无法转换为ExclusiveAppComponent<Activity>的解决办法
- Nacos配置中心用法详细介绍
- Based on TNEWS 'today's headline news in Chinese short text classification
- “灯塔工厂”的中国路径:智造从点到面铺开
- 遇到bug的解决办法,测试再也不背锅了
- try_catch捕获异常
- 【LeetCode每日一题】——230.二叉搜索树中第K小的元素
- CMake Tutorial 巡礼(0)_总述
猜你喜欢

Linux - install MySQL (detailed tutorial)

The range of motion of the robot

The solution to the bug, the test will no longer be blamed

How Navicat Connects to MySQL

i.MX6U-driver development-3-new character driver

go语言解决自定义header的跨域问题

【Incubator DAY18】Interesting exchange【Simulation】【Math】

自学HarmonyOS应用开发(49)- 引入地图功能

LABVIEW详细介绍:LABVIEW是什么软件?都可以干什么?

什么专业越老越吃香?
随机推荐
[Flutter] Detailed explanation of the use of the Flutter inspector tool, viewing the Flutter layout, widget tree, debugging interface, etc.
Superficial understanding of CNN
Vmtouch - under Linux file cache management artifact
推荐系统:用户“行为数据”的采集【使用Kafaka、Cassandra处理数据】【如果与业务数据重合,也需要独自采集】
How many ways does Selenium upload files?I don't believe you have me
Since the media how to write a short video title?Three hot style title, let your video gain more traffic
百度智能云章淼:详解企业级七层负载均衡开源软件BFE
The range of motion of the robot
Detailed introduction of @RequestParam annotation
what is a .pro file in qt
docker安装redis集群(含部署脚本)
Chinese semantic matching
Running a Fabric Application
谷歌浏览器(google)设置翻译中文,翻译选项不生效或没有弹出翻译选项
Win11的WSL2系统更换磁盘和wsl使用简介
Recurrent Neural Network (RNN)
泰克Tektronix示波器软件TDS2012|TDS2014|TDS2022上位机软件NS-Scope
1592. 重新排列单词间的空格
LeetCode/Scala - without the firstborn of the string of characters, the longest text string back
Worthington Dissociation Enzymes: Trypsin and Frequently Asked Questions