From e8d21d84f5fb767d8f179eea7faef4a8976cd8c3 Mon Sep 17 00:00:00 2001 From: Han Yiming Date: Fri, 13 Feb 2026 20:21:18 +0800 Subject: [PATCH] luci-app-tailscale-community: fix exit node conflict when both use advertise exitnode and use another node as exit node will report ERR Signed-off-by: Han Yiming --- .../root/usr/share/rpcd/ucode/tailscale.uc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/applications/luci-app-tailscale-community/root/usr/share/rpcd/ucode/tailscale.uc b/applications/luci-app-tailscale-community/root/usr/share/rpcd/ucode/tailscale.uc index f1e9875949..fe734a47c8 100644 --- a/applications/luci-app-tailscale-community/root/usr/share/rpcd/ucode/tailscale.uc +++ b/applications/luci-app-tailscale-community/root/usr/share/rpcd/ucode/tailscale.uc @@ -143,8 +143,8 @@ methods.set_settings = { let args = ['set']; push(args,'--accept-routes=' + (form_data.accept_routes == '1')); - push(args,'--advertise-exit-node=' + (form_data.advertise_exit_node == '1')); - push(args,'--exit-node-allow-lan-access=' + (form_data.exit_node_allow_lan_access == '1')); + push(args,'--advertise-exit-node=' + ((form_data.advertise_exit_node == '1')&&(form_data.exit_node == ""))); + if (form_data.exit_node == "") push(args,'--exit-node-allow-lan-access=' + (form_data.exit_node_allow_lan_access == '1')); push(args,'--ssh=' + (form_data.ssh == '1')); push(args,'--accept-dns=' + (form_data.disable_magic_dns != '1')); push(args,'--shields-up=' + (form_data.shields_up == '1')); @@ -152,7 +152,7 @@ methods.set_settings = { push(args,'--snat-subnet-routes=' + (form_data.nosnat != '1')); push(args,'--advertise-routes ' + (shell_quote(join(',',form_data.advertise_routes)) || '\"\"')); push(args,'--exit-node=' + (shell_quote(form_data.exit_node) || '\"\"')); - if (form_data.exit_node != "") push(args,' --exit-node-allow-lan-access'); + if (form_data.exit_node != "") push(args,' --exit-node-allow-lan-access=true'); push(args,'--hostname ' + (shell_quote(form_data.hostname) || '\"\"')); let cmd_array = 'tailscale '+join(' ', args);