From 94d5a9e09b097b7cec6253cc940de79664fbe1c6 Mon Sep 17 00:00:00 2001 From: Aofei Sheng Date: Sat, 19 Oct 2024 19:12:29 +0800 Subject: [PATCH] feat: add custom `CLOUDFLARE_WARP_TUNNEL_ENDPOINT` support Signed-off-by: Aofei Sheng --- rootfs/etc/services.d/cloudflare-warp/data/check | 1 + 1 file changed, 1 insertion(+) diff --git a/rootfs/etc/services.d/cloudflare-warp/data/check b/rootfs/etc/services.d/cloudflare-warp/data/check index eaedddf..c30ed18 100755 --- a/rootfs/etc/services.d/cloudflare-warp/data/check +++ b/rootfs/etc/services.d/cloudflare-warp/data/check @@ -12,5 +12,6 @@ while [[ ! -S /run/cloudflare-warp/warp_service ]]; do sleep 0.1; done while [[ ! -f /var/lib/cloudflare-warp/reg.json ]]; do /usr/bin/warp-cli --accept-tos registration new || sleep 5; done /usr/bin/warp-cli --accept-tos mode "${CLOUDFLARE_WARP_MODE:-warp}" /usr/bin/warp-cli --accept-tos tunnel protocol set "${CLOUDFLARE_WARP_TUNNEL_PROTOCOL:-MASQUE}" +[[ -n "${CLOUDFLARE_WARP_TUNNEL_ENDPOINT}" ]] && /usr/bin/warp-cli --accept-tos tunnel endpoint set "${CLOUDFLARE_WARP_TUNNEL_ENDPOINT}" /usr/bin/warp-cli --accept-tos connect while [[ ! -d /sys/class/net/CloudflareWARP ]]; do sleep 0.1; done