AimiliVPN 是一款基于官方 VPNGate 开放协议的高性能、零依赖 VPN 代理网关。它以纯 Python 标准库编写,内置美观响应式的管理网页,提供智能并发测速、多路由模式、出站代理网关、实时日志等强大功能。
| 推荐 | 适合谁 | 亮点 | 入口 |
|---|---|---|---|
| BandwagonHost 搬瓦工 | 更看重国内访问质量、延迟和线路上限的用户 | 顶级三网优化线路,适合对网络体验、跨境访问质量和长期稳定性要求更高的场景 | 立即查看 |
| RackNerd | 想低成本部署、测试、长期挂机的用户 | 每月 6000GB 流量,价格实惠、配置给得足,适合入门部署和性价比优先的 VPS 需求 | 立即查看 |
在您的 Linux VPS 上以 root 用户执行以下对应命令:
bash <(curl -Ls https://raw.githubusercontent.com/baoweise-bot/aimili-vpngate/main/install.sh)
💡 小贴士:部署完成后,终端会输出管理网页的专属链接(含随机安全后缀,如
http://your_vps_ip:8787/u71e9IXp4TPx)。在终端中输入ml命令可以随时调出交互式命令行管理菜单。
部署成功后,如何使用它进行科学上网?
打开浏览器,访问部署完成时提示的专属后台地址(含安全后缀),即可进入精美的暗黑玻璃拟物风管理界面。
为了防止代理端口暴露至公网被恶意扫描和滥用,AimiliVPN 的双效代理服务(默认端口 7928,自适应支持 SOCKS5 和 HTTP 协议)默认仅绑定在本地回环地址(127.0.0.1),只接收 VPS 本机上的流量,不对外机提供代理。
python
import requests
proxies = {
"http": "http://127.0.0.1:7928",
"https": "http://127.0.0.1:7928",
}
response = requests.get("https://www.google.com", proxies=proxies)curl、wget 等)走代理出口:
bash
export http_proxy="http://127.0.0.1:7928"
export https_proxy="http://127.0.0.1:7928"127.0.0.1:7928。💡 小贴士:如果您确实需要对公网其他设备开放此代理端口,可以通过设置环境变量
export LOCAL_PROXY_HOST="::"重新启动服务以允许公网接入。
.log 日志文件到本地。Cannot allocate tun 或 Cannot open tun/tap dev8787)或代理端口(默认 7928)。ufw allow 8787/tcp && ufw allow 7928/tcpfirewall-cmd --zone=public --add-port=8787/tcp --permanent && firewall-cmd --zone=public --add-port=7928/tcp --permanent && firewall-cmd --reloadTCP8787 (管理网页) 和 7928 (代理端口)0.0.0.0/0 (允许所有人,或指定您自己的家庭公网 IP 提高安全性)API Domain Blocked 且备选节点显示为 0/etc/resolv.conf,将域名服务器替换为公共 DNS(如 nameserver 8.8.8.8 和 nameserver 1.1.1.1)。rp_filter),导致策略路由的入站/出站数据包被系统误判丢弃。ml 命令打开交互菜单,工具会自动检测并提示您将 rp_filter 修复为宽松模式(值为 2)。如果您觉得这个项目对您有所帮助,欢迎捐赠支持我们的后续开发与维护:
0xB6d78c42CEB0687A31B8cfEBE4b51b6eB8953C17TSdzCW6JvsrqcppodYjhSrku4mYmDJ9pxf感谢您的慷慨与支持!❤️
AimiliVPN is a high-performance, zero-dependency VPN proxy gateway built entirely using Python's standard library. It parses official VPNGate servers, benchmarks latency, and routes traffic through a built-in dual-protocol (HTTP/SOCKS5) proxy server.
| Pick | Best for | Highlights | Link |
|---|---|---|---|
| BandwagonHost | Users who care most about China connectivity, latency, and route quality | Premium China Telecom/Unicom/Mobile optimized routes, ideal for demanding cross-border networking and long-term use | View deals |
| RackNerd | Budget deployments, testing, and long-running lightweight services | 6000GB monthly bandwidth, affordable pricing, and generous specs for value-focused VPS use | View deals |
Run the corresponding command on your Linux VPS as root:
bash <(curl -Ls https://raw.githubusercontent.com/baoweise-bot/aimili-vpngate/main/install.sh)
💡 Quick Note: Once installed, copy the printed URL from the terminal to access the Web UI. Type the
mlcommand in the terminal to summon the interactive CLI management console.
Open your browser and navigate to the printed URL (e.g. http://your_vps_ip:8787/u71e9IXp4TPx).
To prevent unauthorized scanning and abuse of the proxy port on the public internet, the built-in HTTP/SOCKS5 proxy server (default port 7928) binds to localhost (127.0.0.1) by default. It is designed to route traffic generated locally on the VPS, rather than acting as a public proxy server.
python
import requests
proxies = {
"http": "http://127.0.0.1:7928",
"https": "http://127.0.0.1:7928",
}
response = requests.get("https://www.google.com", proxies=proxies)bash
export http_proxy="http://127.0.0.1:7928"
export https_proxy="http://127.0.0.1:7928"127.0.0.1:7928.💡 Quick Note: If you really need to open this proxy port to the public internet, you can set the environment variable
export LOCAL_PROXY_HOST="::"before running the manager.
Cannot allocate tun or Cannot open tun/tap dev8787 (Web UI) and 7928 (Proxy).ufw allow 8787/tcp && ufw allow 7928/tcpfirewall-cmd --add-port=8787/tcp --permanent && firewall-cmd --add-port=7928/tcp --permanent && firewall-cmd --reload8787 and 7928 from 0.0.0.0/0./etc/resolv.conf (e.g., nameserver 8.8.8.8).If you find this project helpful, you can support its development and maintenance via donation:
0xB6d78c42CEB0687A31B8cfEBE4b51b6eB8953C17TSdzCW6JvsrqcppodYjhSrku4mYmDJ9pxfThank you for your generosity and support! ❤️
$ claude mcp add aimili-vpngate \
-- python -m otcore.mcp_server <graph>