me
/
guix
Archived
1
0
Fork 0

services: agetty: 'term-console' succeeds by default.

Previously, on a typical setup without "console=ttyS0" or similar in
'kernel-arguments', the 'term-console' Shepherd service would always be
marked as failing to start.  This is undesirable because it raises a
false alarm: the service is expected to do nothing in this case.

This patch instead marks it as succeeding and logs a message explaining
it's doing nothing.

* gnu/services/base.scm (agetty-shepherd-service): In 'start' method,
succeed when TTY is #f and print a message.
master
Ludovic Courtès 2023-04-17 15:02:29 +02:00
parent 9fad6067d9
commit 57e731c358
No known key found for this signature in database
GPG Key ID: 090B11993D9AEBB5
1 changed files with 7 additions and 1 deletions

View File

@ -1178,7 +1178,13 @@ to use as the tty. This is primarily useful for headless systems."
#$@(if term #$@(if term
#~(#$term) #~(#$term)
#~()))) #~())))
(const #f)) ; never start. #$(if tty
#~(const #f) ;always fail to start
#~(lambda _ ;succeed, but don't do anything
(format #t "~a: \
no serial port console requested; doing nothing~%"
'#$(car provision))
'idle)))
args))))) args)))))
(stop #~(make-kill-destructor)))))) (stop #~(make-kill-destructor))))))