diff options
author | nbd <nbd@3c298f89-4303-0410-b956-a3cf2f4a3e73> | 2006-01-04 23:50:17 +0000 |
---|---|---|
committer | nbd <nbd@3c298f89-4303-0410-b956-a3cf2f4a3e73> | 2006-01-04 23:50:17 +0000 |
commit | 3f7fe8a080572fb3b989b7e86ca6aa9002b6dfae (patch) | |
tree | 744caf8a1ad803ea5d0d3a78ce2110b3d1a1c045 /package/base-files/default/etc/preinit | |
parent | 283e00c3604f6b98b83abefdfbcbf54c148d91b4 (diff) |
move firstboot to preinit for now (until a better solution is implemented), required by /etc/config/network generator
git-svn-id: svn://svn.openwrt.org/openwrt/trunk/openwrt@2830 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'package/base-files/default/etc/preinit')
-rwxr-xr-x | package/base-files/default/etc/preinit | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/package/base-files/default/etc/preinit b/package/base-files/default/etc/preinit index 88c8920c9..ac9039ca7 100755 --- a/package/base-files/default/etc/preinit +++ b/package/base-files/default/etc/preinit @@ -16,4 +16,9 @@ fi mount_root ${FAILSAFE:+failsafe} +# automagically run firstboot +[ -z "$FAILSAFE" -a -z "$(nvram get no_root_swap)" ] && { + { mount|grep "on / type jffs2" 1>&-; } || firstboot +} + exec /sbin/init |