From 3e5c185446e41e698bfdd64504bd3b5fe6226664 Mon Sep 17 00:00:00 2001 From: Christian Neukirchen Date: Mon, 22 Aug 2016 17:02:01 +0200 Subject: enable serial getty when using serial console --- dracut/getty-serial.sh | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 dracut/getty-serial.sh (limited to 'dracut/getty-serial.sh') diff --git a/dracut/getty-serial.sh b/dracut/getty-serial.sh new file mode 100644 index 0000000..0b85af5 --- /dev/null +++ b/dracut/getty-serial.sh @@ -0,0 +1,12 @@ +#!/bin/sh +# -*- mode: shell-script; indent-tabs-mode: nil; sh-basic-offset: 4; -*- +# ex: ts=8 sw=4 sts=4 et filetype=sh + +type getarg >/dev/null 2>&1 || . /lib/dracut-lib.sh + +CONSOLE=$(getarg console) +case "$CONSOLE" in +*ttyS0*) + ln -s /etc/sv/agetty-ttyS0 ${NEWROOT}/etc/runit/runsvdir/default/ + ;; +esac -- cgit 1.4.1