From bc9de883f6ac4e6c7b9fd6608476d6d2e6039c78 Mon Sep 17 00:00:00 2001 From: sbwml Date: Thu, 30 Mar 2023 12:24:10 +0800 Subject: [PATCH] luci-app-mosdns: config.yaml: fix something unexpected --- .../root/etc/mosdns/config_custom.yaml | 19 +++++++------------ .../root/usr/share/mosdns/default.yaml | 11 +++-------- 2 files changed, 10 insertions(+), 20 deletions(-) diff --git a/luci-app-mosdns/root/etc/mosdns/config_custom.yaml b/luci-app-mosdns/root/etc/mosdns/config_custom.yaml index a706d14..2244c82 100644 --- a/luci-app-mosdns/root/etc/mosdns/config_custom.yaml +++ b/luci-app-mosdns/root/etc/mosdns/config_custom.yaml @@ -222,17 +222,6 @@ plugins: - matches: qtype 65 exec: reject 3 - # 非 拒绝名单 或 DDNS域名 则启用缓存 - - tag: cache - type: sequence - args: - - matches: - - "!qname $ddnslist" - - "!qname $blocklist" - - "!qname $sp_low" - - "!qname $local_ptr" - exec: $lazy_cache - # 主要的运行逻辑插件 # sequence 插件中调用的插件 tag 必须在 sequence 前定义, # 否则 sequence 找不到对应插件。 @@ -241,7 +230,13 @@ plugins: args: - exec: $hosts - exec: jump has_resp_sequence - - exec: $cache + # 非 “拒绝名单” 或 “DDNS域名” 则启用缓存 + - matches: + - "!qname $ddnslist" + - "!qname $blocklist" + - "!qname $sp_low" + - "!qname $local_ptr" + exec: $lazy_cache - exec: $redirect - exec: jump has_resp_sequence - exec: $query_is_ddns_domain diff --git a/luci-app-mosdns/root/usr/share/mosdns/default.yaml b/luci-app-mosdns/root/usr/share/mosdns/default.yaml index c681a85..7821be8 100644 --- a/luci-app-mosdns/root/usr/share/mosdns/default.yaml +++ b/luci-app-mosdns/root/usr/share/mosdns/default.yaml @@ -198,9 +198,11 @@ plugins: - matches: qtype 65 exec: reject 3 - - tag: cache + - tag: main_sequence type: sequence args: + - exec: $hosts + - exec: jump has_resp_sequence - matches: - "!qname $ddnslist" - "!qname $blocklist" @@ -208,13 +210,6 @@ plugins: - "!qname $sp_low" - "!qname $local_ptr" exec: $lazy_cache - - - tag: main_sequence - type: sequence - args: - - exec: $hosts - - exec: jump has_resp_sequence - - exec: $cache - exec: $redirect - exec: jump has_resp_sequence - exec: $query_is_ddns_domain