diff options
author | Juan RP <xtraeme@gmail.com> | 2015-01-28 17:15:51 +0100 |
---|---|---|
committer | Juan RP <xtraeme@gmail.com> | 2015-01-28 17:15:51 +0100 |
commit | af3e795adeedd9218b49ae7b2e8b355b311ed80c (patch) | |
tree | e3695fef3485b06c7ff5e11db49feb3a0e03eb39 | |
parent | fe4cb52bdbc019183927c4dd2f00889852c39641 (diff) | |
download | runit-void-af3e795adeedd9218b49ae7b2e8b355b311ed80c.tar.gz runit-void-af3e795adeedd9218b49ae7b2e8b355b311ed80c.tar.xz runit-void-af3e795adeedd9218b49ae7b2e8b355b311ed80c.zip |
2: accept a custom runlevel via kernel cmdline (from bougyman).
-rwxr-xr-x | 2 | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/2 b/2 index 8440f19..8897503 100755 --- a/2 +++ b/2 @@ -8,6 +8,10 @@ for arg in $(cat /proc/cmdline); do case $arg in single) echo "Initializing single user mode..."; runlevel=single;; esac + if [ -d /etc/runit/runsvdir/"$arg" ]; then + echo "Runlevel detected: '$arg' (via kernel cmdline)" + runlevel="$arg" + fi done [ -x /etc/rc.local ] && /etc/rc.local |