目 录CONTENT

文章目录

fun | 给女朋友推送暖心消息

RobKing
2023-07-06 / 0 评论 / 0 点赞 / 101 阅读 / 225 字

fun | 给女朋友推送暖心消息

官方:https://github.com/wangxinleo/wechat-public-account-push

安装nodejs环境

curl -fsSL https://deb.nodesource.com/setup_16.x | sudo -E bash -

sudo apt-get install -y nodejs

下载项目

cd ~ && git clone https://github.com/wangxinleo/wechat-public-account-push.git

cd ~/wechat-public-account-push

# 二选一:中国内地执行这一步,速度更快
npm install -g cnpm --registry=https://registry.npm.taobao.org  && cnpm install && cnpm install pm2 -g

# 二选一:国外服务器执行这一步
npm install && npm install pm2 -g

填写发送配置

vim ~/wechat-public-account-push/config/index.cjs

填写定时配置

vim ~/wechat-public-account-push/config/server-config.js

运行

npm run pm2start

常用命令

# 停止
pm2 stop @wechat-push 
# 重启
pm2 restart @wechat-push 
# 删除服务
pm2 delete @wechat-push 

# 查看运行日志
pm2 log @wechat-push
# 清空日志
pm2 flush

我的博客:https://robking.top

参考

0

评论区