Skip to content

Commit

Permalink
customize: add natflow by default
Browse files Browse the repository at this point in the history
  • Loading branch information
pmkol authored Sep 10, 2024
1 parent 48ceab5 commit 87ed5fb
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions openwrt/scripts/10-customize-config.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,9 @@ sed -i 's#Loyalsoldier/geoip/releases/latest/download/geoip-only-cn-private.dat#
sed -i '/geoip_api/s#Loyalsoldier/v2ray-rules-dat#pmkol/geodata-lite#' package/new/helloworld/luci-app-passwall/root/usr/share/passwall/rule_update.lua
sed -i '/geosite_api/s#Loyalsoldier/v2ray-rules-dat#MetaCubeX/meta-rules-dat#' package/new/helloworld/luci-app-passwall/root/usr/share/passwall/rule_update.lua

# add natflow by default
sed -i 's|\[\ \$(grep\ -c\ shortcut_fe\ /etc/config/firewall)\ -eq\ '\''0'\''\ \]\ \&\&\ uci\ set\ firewall.@defaults\[0\].flow_offloading='\''1'\''|\[\ \$(grep\ -c\ shortcut_fe\ /etc/config/firewall)\ -eq\ '\''0'\''\ \]\ \&\&\ \[\ \$(grep\ -c\ natflow_delay_pkts\ /etc/config/firewall)\ -eq\ '\''0'\''\ \]\ \&\&\ uci\ set\ firewall.@defaults\[0\].flow_offloading='\''1'\''|g' package/new/default-settings/default/zzz-default-settings

# configure default-settings
sed -i 's/openwrt\/luci/pmkol\/openwrt-plus/g' package/new/luci-theme-argon/luci-theme-argon/luasrc/view/themes/argon/footer.htm
sed -i 's/openwrt\/luci/pmkol\/openwrt-plus/g' package/new/luci-theme-argon/luci-theme-argon/luasrc/view/themes/argon/footer_login.htm
Expand Down

0 comments on commit 87ed5fb

Please sign in to comment.