back to home

eooce / nodejs-argo

nodejs-argo是一个强大的Argo隧道部署工具,专为PaaS平台和游戏玩具平台设计。它支持多种代理协议(VLESS、VMess、Trojan等),并集成了哪吒探针功能,支持npm install nodejs-argo一键安装包

6,840 stars
10,721 forks
13 issues
JavaScriptDockerfile

AI Architecture Analysis

This repository is indexed by RepoMind. By analyzing eooce/nodejs-argo in our AI interface, you can instantly generate complete architecture diagrams, visualize control flows, and perform automated security audits across the entire codebase.

Our Agentic Context Augmented Generation (Agentic CAG) engine loads full source files into context, avoiding the fragmentation of traditional RAG systems. Ask questions about the architecture, dependencies, or specific features to see it in action.

Embed this Badge

Showcase RepoMind's analysis directly in your repository's README.

[![Analyzed by RepoMind](https://img.shields.io/badge/Analyzed%20by-RepoMind-4F46E5?style=for-the-badge)](https://repomind-ai.vercel.app/repo/eooce/nodejs-argo)
Preview:Analyzed by RepoMind

Repository Summary (README)

Preview
<div align="center">

nodejs-argo隧道代理

npm version npm downloads License

nodejs-argo是一个强大的Argo隧道部署工具,专为PaaS平台和游戏玩具平台设计。它支持多种代理协议(VLESS、VMess、Trojan等),并集成了哪吒探针功能。


Telegram交流反馈群组:https://t.me/eooceu

</div>

郑重声明

  • 本项目自2025年10月29日15时45分起,已更改开源协议,并包含以下特定要求
  • 此项目仅限个人使用,禁止用于商业行为(包括但不限于:youtube,bilibili,tiktok,facebook..等等)
  • 禁止新建项目将代码复制到自己仓库中用做商业行为
  • 请遵守当地法律法规,禁止滥用做公共代理行为
  • 如有违反以上条款者将追究法律责任

说明 (部署前请仔细阅读)

  • 本项目是针对node环境的paas平台和游戏玩具而生,采用Argo隧道部署节点,集成哪吒探针v0或v1可选。
  • node玩具平台只需上传index.js和package.json即可,paas平台需要docker部署的才上传Dockerfile。
  • 不填写ARGO_DOMAIN和ARGO_AUTH两个变量即启用临时隧道,反之则使用固定隧道。
  • 哪吒v0/v1可选,当哪吒端口为{443,8443,2096,2087,2083,2053}其中之一时,自动开启tls。

📋 环境变量

变量名是否必须默认值说明
UPLOAD_URL-订阅上传地址
PROJECT_URLhttps://www.google.com项目分配的域名
AUTO_ACCESSfalse是否开启自动访问保活
PORT3000HTTP服务监听端口
ARGO_PORT8001Argo隧道端口
UUID89c13786-25aa-4520-b2e7-12cd60fb5202用户UUID
NEZHA_SERVER-哪吒面板域名
NEZHA_PORT-哪吒端口
NEZHA_KEY-哪吒密钥
ARGO_DOMAIN-Argo固定隧道域名
ARGO_AUTH-Argo固定隧道密钥
CFIPwww.visa.com.tw节点优选域名或IP
CFPORT443节点端口
NAMEVls节点名称前缀
FILE_PATH./tmp运行目录
SUB_PATHsub订阅路径

🌐 订阅地址

  • 标准端口:https://your-domain.com/sub
  • 非标端口:http://your-domain.com:port/sub

🚀 进阶使用

安装

# 全局安装(推荐)
npm install -g nodejs-argo

# 或者使用yarn
yarn global add nodejs-argo

# 或者使用pnpm
pnpm add -g nodejs-argo

基本使用

# 直接运行(使用默认配置)
nodejs-argo

# 使用npx运行
npx nodejs-argo

# 设置环境变量运行
 PORT=3000 npx nodejs-argo

环境变量配置

可使用 .env 文件来配置环境变量运行

或者直接在命令行中设置:

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"

📦 作为npm模块使用

// CommonJS
const nodejsArgo = require('nodejs-argo');

// ES6 Modules
import nodejsArgo from 'nodejs-argo';

// 启动服务
nodejsArgo.start();

🔧 后台运行

使用screen(推荐)

# 创建screen会话
screen -S argo

# 运行应用
nodejs-argo

# 按 Ctrl+A 然后按 D 分离会话
# 重新连接:screen -r argo

使用tmux

# 创建tmux会话
tmux new-session -d -s argo

# 运行应用
tmux send-keys -t argo "nodejs-argo" Enter

# 分离会话:tmux detach -s argo
# 重新连接:tmux attach -t argo

使用PM2

# 安装PM2
npm install -g pm2

# 启动应用
pm2 start nodejs-argo --name "argo-service"

# 管理应用
pm2 status
pm2 logs argo-service
pm2 restart argo-service

使用systemd(Linux系统服务)

# 创建服务文件
sudo nano /etc/systemd/system/nodejs-argo.service

[Unit] Description=Node.js Argo Service After=network.target

[Service] Type=simple User=root WorkingDirectory=/root/test Environment=ARGO_PORT=8080 Environment=PORT=3000 ExecStart=/usr/bin/npx nodejs-argo Restart=always RestartSec=10

[Install] WantedBy=multi-user.target


# 启动服务
sudo systemctl start nodejs-argo
sudo systemctl enable nodejs-argo

🔄 更新

# 更新全局安装的包
npm update -g nodejs-argo

# 或者重新安装
npm uninstall -g nodejs-argo
npm install -g nodejs-argo

📚 更多信息


赞助

  • 感谢VPS.Town提供赞助 <a href="https://vps.town" target="_blank"><img src="https://vps.town/static/images/sponsor.png" width="30%" alt="https://vps.town"></a>

  • 感谢ZMTO提供赞助优质双isp vps。