
Security News
Inside Lodash’s Security Reset and Maintenance Reboot
Lodash 4.17.23 marks a security reset, with maintainers rebuilding governance and infrastructure to support long-term, sustainable maintenance.
SBX是一个强大的多功能代理节点部署工具,支持多种协议(VMess、VLESS、Hysteria2、TUIC、Reality),集成了Argo隧道和哪吒探针功能。专为PaaS平台和VPS环境设计。
# 全局安装(推荐)
npm install -g node-sbx
# 使用yarn
yarn global add node-sbx
# 使用pnpm
pnpm add -g node-sbx
# 直接运行(使用默认配置)
node-sbx
# 使用npx运行
npx node-sbx
# 设置环境变量运行
PORT=3000 node-sbx
# 复制示例文件
cp .env.example .env
# 编辑配置文件
nano .env
| 变量名 | 是否必须 | 默认值 | 说明 |
|---|---|---|---|
UPLOAD_URL | 否 | - | 订阅或节点自动上传地址 |
PROJECT_URL | 否 | - | 项目分配的域名 |
AUTO_ACCESS | 否 | false | 是否开启自动访问保活 |
FILE_PATH | 否 | ./.npm | 订阅文件保存路径 |
SUB_PATH | 否 | sub | 订阅路径 |
UUID | 否 | aca4e9de-9705-428c-a8f2-3c34938dc62c | 用户UUID |
NEZHA_SERVER | 否 | - | 哪吒面板地址 |
NEZHA_PORT | 否 | - | 哪吒端口(v0需要) |
NEZHA_KEY | 否 | - | 哪吒密钥 |
ARGO_DOMAIN | 否 | - | Argo固定隧道域名 |
ARGO_AUTH | 否 | - | Argo固定隧道token或json |
ARGO_PORT | 否 | 8001 | Argo隧道端口 |
TUIC_PORT | 否 | - | TUIC端口,设置为有效端口号(1-65535) |
HY2_PORT | 否 | - | Hysteria2端口,设置为有效端口号(1-65535) |
REALITY_PORT | 否 | - | Reality端口,设置为有效端口号(1-65535) |
CFIP | 否 | www.visa.com.tw | 优选域名或IP |
CFPORT | 否 | 443 | 优选端口 |
PORT | 否 | 3000 | HTTP服务端口 |
NAME | 否 | Vls | 节点名称前缀 |
CHAT_ID | 否 | - | Telegram chat_id |
BOT_TOKEN | 否 | - | Telegram bot_token |
# 基本配置
export UPLOAD_URL="https://your-merge-sub-domain.com"
export PROJECT_URL="https://your-project-domain.com"
export PORT=3000
export UUID="your-uuid-here"
# 哪吒探针配置
export NEZHA_SERVER="nz.your-domain.com:8008"
export NEZHA_KEY="your-nezha-key"
# Argo隧道配置
export ARGO_DOMAIN="your-argo-domain.com"
export ARGO_AUTH="your-argo-token"
# Telegram推送配置
export CHAT_ID="your-chat-id"
export BOT_TOKEN="your-bot-token"
// CommonJS
const sbx = require('node-sbx');
// ES6 Modules
import sbx from 'node-sbx';
# 创建screen会话
screen -S sbx
# 运行应用
sbx
# 按 Ctrl+A 然后按 D 分离会话
# 重新连接:screen -r sbx
# 创建tmux会话
tmux new-session -d -s sbx
# 运行应用
tmux send-keys -t sbx "sbx" Enter
# 分离会话:tmux detach -s sbx
# 重新连接:tmux attach -t sbx
# 安装PM2
npm install -g pm2
# 启动应用
pm2 start sbx --name "sbx-service"
# 管理应用
pm2 status
pm2 logs sbx-service
pm2 restart sbx-service
# 创建服务文件
sudo nano /etc/systemd/system/sbx.service
服务文件内容:
[Unit]
Description=SBX Proxy Service
After=network.target
[Service]
Type=simple
User=root
WorkingDirectory=/root
Environment=UPLOAD_URL=https://your-domain.com
Environment=PROJECT_URL=https://your-project.com
Environment=PORT=3000
ExecStart=/usr/bin/sbx
Restart=always
RestartSec=10
[Install]
WantedBy=multi-user.target
启动服务:
sudo systemctl daemon-reload
sudo systemctl start sbx
sudo systemctl enable sbx
sudo systemctl status sbx
https://your-domain.com/subhttp://your-domain.com:port/subTUIC_PORT 设置为有效端口号(1-65535)时生成HY2_PORT 设置为有效端口号(1-65535)时生成REALITY_PORT 设置为有效端口号(1-65535)时生成
## 🔄 更新
```bash
# 更新全局安装的包
npm update -g @eooce/sbx
# 或者重新安装
npm uninstall -g @eooce/sbx
npm install -g @eooce/sbx
欢迎提交Issue和Pull Request来改进这个项目!
本项目采用MIT许可证 - 查看LICENSE文件了解详情。
本程序仅供学习了解,非盈利目的,请于下载后24小时内删除,不得用作任何商业用途。使用本程序必须遵守部署服务器所在地、所在国家和用户所在国家的法律法规,程序作者不对使用者任何不当行为负责。
FAQs
node-sbx
The npm package node-sbx receives a total of 382 weekly downloads. As such, node-sbx popularity was classified as not popular.
We found that node-sbx demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
Lodash 4.17.23 marks a security reset, with maintainers rebuilding governance and infrastructure to support long-term, sustainable maintenance.

Security News
n8n led JavaScript Rising Stars 2025 by a wide margin, with workflow platforms seeing the largest growth across categories.

Security News
The U.S. government is rolling back software supply chain mandates, shifting from mandatory SBOMs and attestations to a risk-based approach.