File tree Expand file tree Collapse file tree 2 files changed +16
-3
lines changed
luci-app-passwall/luasrc/passwall Expand file tree Collapse file tree 2 files changed +16
-3
lines changed Original file line number Diff line number Diff line change @@ -1813,7 +1813,9 @@ function gen_config(var)
18131813 table.insert (dns .rules , {
18141814 query_type = { " A" , " AAAA" },
18151815 server = fakedns_tag ,
1816- disable_cache = true
1816+ disable_cache = true ,
1817+ rewrite_ttl = 30 ,
1818+ strategy = remote_strategy
18171819 })
18181820 end
18191821 end
Original file line number Diff line number Diff line change @@ -1047,14 +1047,25 @@ function gen_config(var)
10471047 else
10481048 local preproxy_node = get_node_by_id (node .preproxy_node )
10491049 if preproxy_node then
1050- local preproxy_outbound = gen_outbound (node [" .name" ], preproxy_node )
1050+ local preproxy_outbound , exist
1051+ if preproxy_node .protocol == " _balancing" then
1052+ local balancer_tag , loopback_outbound = gen_balancer (preproxy_node )
1053+ if loopback_outbound then
1054+ preproxy_outbound = loopback_outbound
1055+ exist = true
1056+ end
1057+ else
1058+ preproxy_outbound = gen_outbound (node [" .name" ], preproxy_node )
1059+ end
10511060 if preproxy_outbound then
10521061 outbound .tag = preproxy_outbound .tag .. " -> " .. outbound .tag
10531062 outbound .proxySettings = {
10541063 tag = preproxy_outbound .tag ,
10551064 transportLayer = true
10561065 }
1057- last_insert_outbound = preproxy_outbound
1066+ if not exist then
1067+ last_insert_outbound = preproxy_outbound
1068+ end
10581069 default_outTag = outbound .tag
10591070 end
10601071 end
You can’t perform that action at this time.
0 commit comments