mirror of
https://github.com/openwrt/openwrt.git
synced 2024-12-23 15:32:33 +00:00
cb9bb908de
vconfig has been disabled by default since 2015 [1] and there are
no remaining uses in entire OpenWrt trunk. However, we still set up
a specific name_type for it during boot.
While this setup is properly implemented to be only triggered when
vconfig is present, it still seems anachronistic and unnecessary
to set up a standard for a tool that is not used anymore.
Therefore, this removes the set_name_type initialization and leaves
it for those people actually using the tool to configure it as needed.
[1] 899a23227e
("busybox: improve applets & deprecate ifconfig, route")
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
53 lines
1.2 KiB
Bash
Executable File
53 lines
1.2 KiB
Bash
Executable File
#!/bin/sh /etc/rc.common
|
|
# Copyright (C) 2006-2011 OpenWrt.org
|
|
|
|
START=10
|
|
STOP=90
|
|
|
|
uci_apply_defaults() {
|
|
. /lib/functions/system.sh
|
|
|
|
cd /etc/uci-defaults || return 0
|
|
files="$(ls)"
|
|
[ -z "$files" ] && return 0
|
|
mkdir -p /tmp/.uci
|
|
for file in $files; do
|
|
( . "./$(basename $file)" ) && rm -f "$file"
|
|
done
|
|
uci commit
|
|
}
|
|
|
|
boot() {
|
|
[ -f /proc/mounts ] || /sbin/mount_root
|
|
[ -f /proc/jffs2_bbc ] && echo "S" > /proc/jffs2_bbc
|
|
|
|
mkdir -p /var/run
|
|
mkdir -p /var/log
|
|
mkdir -p /var/lock
|
|
mkdir -p /var/state
|
|
mkdir -p /var/tmp
|
|
mkdir -p /tmp/.uci
|
|
chmod 0700 /tmp/.uci
|
|
touch /var/log/wtmp
|
|
touch /var/log/lastlog
|
|
mkdir -p /tmp/resolv.conf.d
|
|
touch /tmp/resolv.conf.d/resolv.conf.auto
|
|
ln -sf /tmp/resolv.conf.d/resolv.conf.auto /tmp/resolv.conf
|
|
grep -q debugfs /proc/filesystems && /bin/mount -o noatime -t debugfs debugfs /sys/kernel/debug
|
|
grep -q bpf /proc/filesystems && /bin/mount -o nosuid,nodev,noexec,noatime,mode=0700 -t bpf bpffs /sys/fs/bpf
|
|
[ "$FAILSAFE" = "true" ] && touch /tmp/.failsafe
|
|
|
|
/sbin/kmodloader
|
|
|
|
[ ! -f /etc/config/wireless ] && {
|
|
# compat for bcm47xx and mvebu
|
|
sleep 1
|
|
}
|
|
|
|
/bin/config_generate
|
|
uci_apply_defaults
|
|
|
|
# temporary hack until configd exists
|
|
/sbin/reload_config
|
|
}
|