feat: add wireguard relay integration for public server access with End-to-End Encryption

Integrates tunwg (WireGuard tunnel) to enable optional public access
to the hapi server. Tunnel is disabled by default and enabled via
--relay flag or HAPI_TUNNEL=true environment variable.

Users can now run 'hapi server --relay' and get a direct link like:
https://app.hapi.run/?server=https://xxx.relay.hapi.run&token=xxx
This commit is contained in:
weishu
2026-01-13 20:18:11 +08:00
parent ecae91fa1c
commit 5defb6dbfc
22 changed files with 723 additions and 28 deletions
+30
View File
@@ -12,3 +12,33 @@ declare module '*-LICENSE' {
const path: string;
export default path;
}
declare module '*/tunwg/LICENSE' {
const path: string;
export default path;
}
declare module '*/tunwg/tunwg-arm64-darwin' {
const path: string;
export default path;
}
declare module '*/tunwg/tunwg-x64-darwin' {
const path: string;
export default path;
}
declare module '*/tunwg/tunwg-arm64-linux' {
const path: string;
export default path;
}
declare module '*/tunwg/tunwg-x64-linux' {
const path: string;
export default path;
}
declare module '*/tunwg/tunwg-x64-win32.exe' {
const path: string;
export default path;
}