From aaae6121b5a52c406595df87540878fef16d287d Mon Sep 17 00:00:00 2001 From: Paul Sokolovsky Date: Sun, 2 Dec 2007 15:22:08 +0000 Subject: dropbear-early: Package which allows to start dropbear ASAP after the kernel boot. * Note: *allows*, not starts. To do that, "dropbear=early" should be passed on kernel command line. --- packages/dropbear/dropbear-early/.mtn2git_empty | 0 packages/dropbear/dropbear-early/dropbear-early | 10 ++++++++++ packages/dropbear/dropbear-early_1.0.bb | 17 +++++++++++++++++ 3 files changed, 27 insertions(+) create mode 100644 packages/dropbear/dropbear-early/.mtn2git_empty create mode 100644 packages/dropbear/dropbear-early/dropbear-early create mode 100644 packages/dropbear/dropbear-early_1.0.bb diff --git a/packages/dropbear/dropbear-early/.mtn2git_empty b/packages/dropbear/dropbear-early/.mtn2git_empty new file mode 100644 index 0000000000..e69de29bb2 diff --git a/packages/dropbear/dropbear-early/dropbear-early b/packages/dropbear/dropbear-early/dropbear-early new file mode 100644 index 0000000000..fa06a93003 --- /dev/null +++ b/packages/dropbear/dropbear-early/dropbear-early @@ -0,0 +1,10 @@ +#!/bin/sh + +for x in $(cat /proc/cmdline); do + case $x in + dropbear=early) + echo "Starting dropbear early" + exec /etc/init.d/dropbear $* + ;; + esac +done diff --git a/packages/dropbear/dropbear-early_1.0.bb b/packages/dropbear/dropbear-early_1.0.bb new file mode 100644 index 0000000000..651d1327ca --- /dev/null +++ b/packages/dropbear/dropbear-early_1.0.bb @@ -0,0 +1,17 @@ +DESCRIPTION = "Allow to start dropbear soon after boot, depending on kernel command line option." +SECTION = "devel" +PR = "r1" + +SRC_URI = "file://dropbear-early" + +inherit update-rc.d + +do_install() { + install -d ${D}${sysconfdir}/init.d + install -m 0755 ${WORKDIR}/${INITSCRIPT_NAME} ${D}${sysconfdir}/init.d/ +} + +PACKAGE_ARCH = "all" + +INITSCRIPT_NAME = "dropbear-early" +INITSCRIPT_PARAMS = "start 00 S ." -- cgit v1.2.3