diskimage-builder/elements/serial-console/install.d/ttySx.conf
Robert Collins a8707cc152 Add an element to configure a serial console.
With ILO and other remote machine management cards, a serial console is
actually useful.

Change-Id: I86f74d9dae3821b4682df813c5b52a83a29a138a
2013-05-10 07:38:31 +12:00

16 lines
452 B
Plaintext

# This service maintains a getty on ttyS0/1 from the point the system is
# started until it is shut down again.
start on stopped rc or RUNLEVEL=[2345]
stop on runlevel [!2345]
respawn
script
console_port=0
echo "ttySx probing ttyS1" >/dev/ttyS1 2>/dev/null && console_port=1
echo "ttySx: console tty = /dev/ttyS$console_port" >&2
exec /sbin/agetty -m ttyS$console_port 115200,57600,38400,9600,4800 vt102
end script