Skip to content

Commit

Permalink
Set dnsmasq config after nft set are created (#443)
Browse files Browse the repository at this point in the history
  • Loading branch information
suyuan168 authored Feb 26, 2024
2 parents 4cca910 + 0f16943 commit aac6bfe
Showing 1 changed file with 6 additions and 7 deletions.
13 changes: 6 additions & 7 deletions omr-bypass/files/etc/init.d/omr-bypass-nft
Original file line number Diff line number Diff line change
Expand Up @@ -560,13 +560,6 @@ _intf_rule() {
[ -z "$intf" ] && return
# [ -z "$RELOAD" ] || [ "$(uci show firewall.omr_dst_bypass_$intf_4)" = "" ] && {
#unset RELOAD
#echo "$intf ip set dhcp"
uci batch <<-EOF
set dhcp.omr_dst_bypass_$intf=ipset
add_list dhcp.omr_dst_bypass_$intf.name="omr_dst_bypass_${intf}_4"
add_list dhcp.omr_dst_bypass_$intf.name="omr_dst_bypass_${intf}_6"
commit dhcp
EOF
#echo "firewall omr_dst_bypass ipset"
uci -q batch <<-EOF
set firewall.omr_dst_bypass_${intf}_4=ipset
Expand Down Expand Up @@ -678,6 +671,12 @@ _intf_rule() {
commit network
EOF
fi
uci batch <<-EOF
set dhcp.omr_dst_bypass_$intf=ipset
add_list dhcp.omr_dst_bypass_$intf.name="omr_dst_bypass_${intf}_4"
add_list dhcp.omr_dst_bypass_$intf.name="omr_dst_bypass_${intf}_6"
commit dhcp
EOF

if [ "$(uci -q get openmptcprouter.settings.proxy)" = "shadowsocks" ]; then
config_load shadowsocks-libev
Expand Down

0 comments on commit aac6bfe

Please sign in to comment.