mirror of
https://github.com/kiddin9/op-packages.git
synced 2026-11-03 00:53:56 +08:00
🌴 Sync 2026-03-05 23:51:42
This commit is contained in:
1 parent
97c049ed0a
commit
0acff03804
14253 files changed
+3893239
No files matched your search
Whitespace-only changes.
+32
@@ -0,0 +1,32 @@
|
||||
#!/bin/sh
|
||||
|
||||
CFG=$1
|
||||
|
||||
IP_PROTO=dhcp
|
||||
IP_ADDRESS=
|
||||
|
||||
[ -n "$CFG" ] || CFG=/etc/board.json
|
||||
|
||||
. /lib/functions/uci-defaults.sh
|
||||
|
||||
board_config_update
|
||||
|
||||
json_is_a network object && exit 0
|
||||
|
||||
ucidef_set_hostname "iStoreOS"
|
||||
|
||||
ucidef_set_timezone "CST-8"
|
||||
|
||||
ucidef_set_ntpserver "0.cn.pool.ntp.org" "1.cn.pool.ntp.org" "2.cn.pool.ntp.org" "3.cn.pool.ntp.org"
|
||||
|
||||
if [ "static" = "$IP_PROTO" -a -n "$IP_ADDRESS" ]; then
|
||||
eval $(ipcalc.sh "$IP_ADDRESS")
|
||||
ucidef_set_interface_lan "eth0"
|
||||
ucidef_set_interface "lan" ipaddr "$IP" netmask "$NETMASK"
|
||||
else
|
||||
ucidef_set_interface_lan "eth0" "dhcp"
|
||||
fi
|
||||
|
||||
board_config_flush
|
||||
|
||||
[ -s "$CFG" ] || return 1
|
||||
@@ -0,0 +1,12 @@
|
||||
# This file is interpreted as shell script.
|
||||
# Put your custom iptables rules here, they will
|
||||
# be executed with each firewall (re-)start.
|
||||
|
||||
# Internal uci firewall chains are flushed and recreated on reload, so
|
||||
# put custom rules into the root chains e.g. INPUT or FORWARD or into the
|
||||
# special user chains, e.g. input_wan_rule or postrouting_lan_rule.
|
||||
|
||||
# workaround route shortcut issue in shadowrt clones on openwrt 22.03
|
||||
iptables -t mangle -I PREROUTING -p tcp -m conntrack --ctstate RELATED,ESTABLISHED -m socket -j ACCEPT || true
|
||||
ip6tables -t mangle -I PREROUTING -p tcp -m conntrack --ctstate RELATED,ESTABLISHED -m socket -j ACCEPT || true
|
||||
|
||||
+38
@@ -0,0 +1,38 @@
|
||||
#!/bin/sh
|
||||
|
||||
uci -q batch <<-EOF >/dev/null
|
||||
set quickstart.main.disable_dhns=1
|
||||
commit quickstart
|
||||
EOF
|
||||
|
||||
uci -q batch <<-EOF >/dev/null
|
||||
set argon.@global[0].primary='#5b7e99'
|
||||
set argon.@global[0].dark_primary='#337d8c'
|
||||
commit argon
|
||||
EOF
|
||||
|
||||
GATEWAY=
|
||||
DNS=
|
||||
DHCP_SERVER=
|
||||
|
||||
[ -n "$GATEWAY" ] && uci set network.lan.gateway="$GATEWAY"
|
||||
if [ -n "$DNS" ]; then
|
||||
for dns in $DNS; do
|
||||
uci add_list network.lan.dns="$dns"
|
||||
done
|
||||
fi
|
||||
uci commit network
|
||||
|
||||
uci -q batch <<-EOF >/dev/null
|
||||
del dhcp.lan.ra
|
||||
del dhcp.lan.ra_slaac
|
||||
del dhcp.lan.ra_flags
|
||||
del dhcp.lan.dhcpv6
|
||||
EOF
|
||||
|
||||
if [ -z "$DHCP_SERVER" ]; then
|
||||
uci set dhcp.lan.ignore='1'
|
||||
fi
|
||||
uci commit dhcp
|
||||
|
||||
exit 0
|
||||
@@ -0,0 +1,8 @@
|
||||
do_sysinfo_generic() {
|
||||
mkdir -p /tmp/sysinfo
|
||||
|
||||
echo "docker" > /tmp/sysinfo/board_name
|
||||
echo "Docker" > /tmp/sysinfo/model
|
||||
}
|
||||
|
||||
boot_hook_add preinit_main do_sysinfo_generic
|
||||
+4
@@ -0,0 +1,4 @@
|
||||
#!/bin/sh
|
||||
echo "ignore '$0 $@' in container" >&2
|
||||
exit 0
|
||||
|
||||
@@ -0,0 +1 @@
|
||||
/usr/libexec/kmodloader
|
||||
@@ -0,0 +1 @@
|
||||
/usr/libexec/kmodloader
|
||||
Whitespace-only changes.
Whitespace-only changes.
Reference in new issue
Block a user