[SCM] live-config branch, debian, updated. debian/2.0_a11-1-4-g8a3631d
Daniel Baumann
daniel at debian.org
Wed Jul 7 18:23:12 UTC 2010
The following commit has been merged in the debian branch:
commit 11974af5fecbb5126da9a07f63b8d69dc72ec7c5
Author: Daniel Baumann <daniel at debian.org>
Date: Sun Jun 27 18:55:11 2010 +0200
Factoring out common function to start network.
diff --git a/scripts/config.sh b/scripts/config.sh
index 2fe1f0e..dc00229 100755
--- a/scripts/config.sh
+++ b/scripts/config.sh
@@ -179,6 +179,21 @@ Trap ()
return ${_RETURN}
}
+Start_network ()
+{
+ if [ -z "${_NETWORK}" ] && [ -e /etc/init.d/live-config ]
+ then
+ /etc/init.d/mountkernfs.sh start > /dev/null 2>&1
+ /etc/init.d/mountdevsubfs.sh start > /dev/null 2>&1
+ /etc/init.d/ifupdown-clean start > /dev/null 2>&1
+ /etc/init.d/ifupdown start > /dev/null 2>&1
+ /etc/init.d/networking start > /dev/null 2>&1
+
+ _NETWORK="true"
+ export _NETWORK
+ fi
+}
+
Main ()
{
if ! grep -qs "boot=live" /proc/cmdline
diff --git a/scripts/config/999-hooks b/scripts/config/999-hooks
index 2734bb5..d4b0450 100755
--- a/scripts/config/999-hooks
+++ b/scripts/config/999-hooks
@@ -32,18 +32,7 @@ Process_hooks ()
cp $(echo ${_HOOK} | sed 's|file\://||') "${_TMPFILE}"
else
# remote file
-
- if [ -z "${_NETWORK}" ] && [ -e /etc/init.d/live-config ]
- then
- /etc/init.d/mountkernfs.sh start > /dev/null 2>&1
- /etc/init.d/mountdevsubfs.sh start > /dev/null 2>&1
- /etc/init.d/ifupdown-clean start > /dev/null 2>&1
- /etc/init.d/ifupdown start > /dev/null 2>&1
- /etc/init.d/networking start > /dev/null 2>&1
-
- _NETWORK="true"
- export _NETWORK
- fi
+ Start_network
wget --quiet "${_HOOK}" -O "${_TMPFILE}"
fi
--
live-config
More information about the debian-live-changes
mailing list