惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

博客园 - 【当耐特】
Help Net Security
Help Net Security
P
Proofpoint News Feed
J
Java Code Geeks
爱范儿
爱范儿
Last Week in AI
Last Week in AI
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
F
Full Disclosure
Google DeepMind News
Google DeepMind News
H
Help Net Security
G
Google Developers Blog
Jina AI
Jina AI
Vercel News
Vercel News
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
L
Lohrmann on Cybersecurity
S
Schneier on Security
Microsoft Azure Blog
Microsoft Azure Blog
IT之家
IT之家
Security Archives - TechRepublic
Security Archives - TechRepublic
阮一峰的网络日志
阮一峰的网络日志
N
News and Events Feed by Topic
GbyAI
GbyAI
B
Blog
O
OpenAI News
博客园_首页
Cisco Talos Blog
Cisco Talos Blog
K
KPMG report finds enterprise disconnect between AI and its ROI | CIO
Hacker News: Ask HN
Hacker News: Ask HN
TaoSecurity Blog
TaoSecurity Blog
腾讯CDC
MongoDB | Blog
MongoDB | Blog
M
MIT News - Artificial intelligence
C
Cybersecurity and Infrastructure Security Agency CISA
Cyberwarzone
Cyberwarzone
Webroot Blog
Webroot Blog
Simon Willison's Weblog
Simon Willison's Weblog
Y
Y Combinator Blog
C
Cisco Blogs
A
Arctic Wolf
CTFtime.org: upcoming CTF events
CTFtime.org: upcoming CTF events
T
The Exploit Database - CXSecurity.com
Security Latest
Security Latest
AI
AI
W
WeLiveSecurity
aimingoo的专栏
aimingoo的专栏
The Register - Security
The Register - Security
Project Zero
Project Zero
H
Hackread – Cybersecurity News, Data Breaches, AI and More
N
Netflix TechBlog - Medium
Blog — PlanetScale
Blog — PlanetScale

WishMeLz - Linux

目标域名在线测试 - WishMeLz puppeteer在Linux端 依赖库确实 libdrm.so.2,libnss3.so Linux 工具箱整理 - WishMeLz docker 镜像加速 - WishMeLz Certimate 使用教程 - WishMeLz ip自签名ssl证书 - WishMeLz PM2搭配nvm使用不同版本Node启动项目 - WishMeLz cors-anywhere Nodejs实现静态资源代理,使用ESA加速访问 - WishMeLz shell脚本备份数据库 - WishMeLz
NodeBB 搭建安装笔记 v4.x - WishMeLz
Wish · 2025-11-11 · via WishMeLz - Linux

以下所有的操作 base 都在 /app

Node 版本

node -v
v20.19.5

npm -v
10.8.2

安装

git clone https://github.com/NodeBB/NodeBB.git
cd NodeBB
./nodebb setup

2025-11-11T06:17:01.png

PM2 启动

创建日志文件和pm2启动文件

mkdir -p /app/NodeBB/logs
nano ecosystem.config.js
module.exports = {
  apps: [{
    name: 'nodebb',
    script: './loader.js',
    cwd: '/app/NodeBB',
    instances: 1,
    exec_mode: 'fork',
    watch: false,
    env: {
      NODE_ENV: 'production',
      PORT: 4567
    },
    error_file: './logs/pm2-error.log',
    out_file: './logs/pm2-out.log',
    log_date_format: 'YYYY-MM-DD HH:mm:ss Z',
    merge_logs: true,
    autorestart: true
  }]
};
pm2 start ecosystem.config.js
pm2 startup
pm2 save

2025-11-11T06:24:35.png

配置反向代理

location ^~ / {

    proxy_pass http://127.0.0.1:4567;
    proxy_set_header Host $http_host;
    proxy_set_header X-Real-IP $remote_addr;
    proxy_set_header X-Real-Port $remote_port;
    proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
    proxy_set_header X-Forwarded-Proto $scheme;
    proxy_set_header X-Forwarded-Host $host;
    proxy_set_header X-Forwarded-Port $server_port;
    proxy_set_header REMOTE-HOST $remote_addr;
    
    proxy_connect_timeout 60s;
    proxy_send_timeout 600s;
    proxy_read_timeout 600s;
    proxy_http_version 1.1;
    proxy_set_header Upgrade $http_upgrade;
    proxy_set_header Connection $connection_upgrade;

}

2025-11-11T06:39:30.png


最后编辑时间为: November 11th , 2025 at 02:40 pm
本文由 Wish 创作,采用 知识共享署名 4.0 国际许可协议进行许可
可自由转载、引用,但需署名作者且注明文章出处

标签 : NodeBB