刚上传上来 https://github.com/yumusb/nezha-new
仅供尝鲜,后续不维护,可以与v0共存。BUG多多,仅能正常安装。
无需公网IP,全程都在CF下。
服务端
- 安装好docker
- 申请 CloudFlare Tunnel Token
https://developers.cloudflare.com/cloudflare-one/connections/connect-networks/get-started/create-remote-tunnel/ - CloudFlare开启GRPC流量代理
https://developers.cloudflare.com/network/grpc-connections/ - 服务端启动
编辑一下 conf.d/main.conf 中的两个域名,第一个用来心跳,第二个用来访问git clone https://github.com/yumusb/nezha-new.git
编辑 .env 文件中的 TUNNEL_TOKEN 为自己申请的docker compose up -d - 服务端映射到CF
CloudFlare Tunnel 加两个Public hostname 如下,都指向 http://nginx:80

不出意外,现在可以正常访问了到。
AGENT
- 查看密钥
在服务端data/config.yaml文件里面的agentsecretkey字段

- 脚本安装
wget https://raw.githubusercontent.com/yumusb/nezha-new/refs/heads/main/installagent.sh chmod +x ./installagent.sh ./installagent.sh 密钥 心跳域名:443 true
其他
后台地址 /dashboard
默认密码 admin/admin
感谢分享
好
哪来的无公网小鸡,难道拿移动云电脑D成Linux放探针?
@fastoo #3 无需公网 不代表无公网。全程使用 cloudflare tunnel 不开放端口到公网。
@3az7qmfd #4
有什么必要性吗,没想到
@fastoo #5
这些还不够么?
@3az7qmfd #6
还真是
牛哇
感谢分享
bd