From patchwork Thu Feb 3 20:55:19 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Danny Milosavljevic X-Patchwork-Id: 36962 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id CA7A227BBEA; Thu, 3 Feb 2022 21:09:15 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.9 required=5.0 tests=BAYES_00,MAILING_LIST_MULTI, SPF_HELO_PASS autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 81B5727BBE9 for ; Thu, 3 Feb 2022 21:09:15 +0000 (GMT) Received: from localhost ([::1]:34298 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nFjLu-0001us-M1 for patchwork@mira.cbaines.net; Thu, 03 Feb 2022 16:09:14 -0500 Received: from eggs.gnu.org ([209.51.188.92]:44908) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nFj9T-00036G-J1 for guix-patches@gnu.org; Thu, 03 Feb 2022 15:56:27 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:35934) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nFj99-000161-Bi for guix-patches@gnu.org; Thu, 03 Feb 2022 15:56:19 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1nFj99-0002h0-Bt for guix-patches@gnu.org; Thu, 03 Feb 2022 15:56:03 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#53763] [PATCH 1/3] services: agetty: Add shepherd-requirement. Resent-From: dannym@scratchpost.org Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Thu, 03 Feb 2022 20:56:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 53763 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 53763@debbugs.gnu.org Cc: Danny Milosavljevic Received: via spool by 53763-submit@debbugs.gnu.org id=B53763.164392174110297 (code B ref 53763); Thu, 03 Feb 2022 20:56:03 +0000 Received: (at 53763) by debbugs.gnu.org; 3 Feb 2022 20:55:41 +0000 Received: from localhost ([127.0.0.1]:58061 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nFj8n-0002g1-04 for submit@debbugs.gnu.org; Thu, 03 Feb 2022 15:55:41 -0500 Received: from dd30410.kasserver.com ([85.13.145.193]:38786) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nFj8c-0002f6-83 for 53763@debbugs.gnu.org; Thu, 03 Feb 2022 15:55:39 -0500 Received: from dayas.lan (84-115-234-128.cable.dynamic.surfer.at [84.115.234.128]) by dd30410.kasserver.com (Postfix) with ESMTPSA id 9E2C111202F7; Thu, 3 Feb 2022 21:55:28 +0100 (CET) From: dannym@scratchpost.org Date: Thu, 3 Feb 2022 21:55:19 +0100 Message-Id: <20220203205521.25145-1-dannym@scratchpost.org> X-Mailer: git-send-email 2.34.0 In-Reply-To: <20220203205243.25095-1-dannym@scratchpost.org> References: <20220203205243.25095-1-dannym@scratchpost.org> MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" X-getmail-retrieved-from-mailbox: Patches From: Danny Milosavljevic * gnu/services/base.scm (): Add shepherd-requirement. * doc/guix.texi (agetty-configuration): Document it. --- doc/guix.texi | 4 ++++ gnu/services/base.scm | 8 ++++++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/doc/guix.texi b/doc/guix.texi index aaa7cbb66f..68c4c4086a 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -16634,6 +16634,10 @@ This option accepts, as an integer, the nice value with which to run the This option provides an ``escape hatch'' for the user to provide arbitrary command-line arguments to @command{agetty} as a list of strings. +@item @code{shepherd-requirement} (default: @code{'()}) +The option can be used to provides extra shepherd requirements (for example +@code{'syslogd}) to the respective @code{'term-}* shepherd service. + @end table @end deftp diff --git a/gnu/services/base.scm b/gnu/services/base.scm index fbd01e84d6..d6f584abdb 100644 --- a/gnu/services/base.scm +++ b/gnu/services/base.scm @@ -876,6 +876,8 @@ (define-record-type* ;; "Escape hatch" for passing arbitrary command-line arguments. (extra-options agetty-extra-options ;list of strings (default '())) + (shepherd-requirement agetty-shepherd-requirement ;list of SHEPHERD requirements + (default '())) ;;; XXX Unimplemented for now! ;;; (issue-file agetty-issue-file ;file-like ;;; (default #f)) @@ -924,7 +926,8 @@ (define agetty-shepherd-service host no-issue? init-string no-clear? local-line extract-baud? skip-login? no-newline? login-options chroot hangup? keep-baud? timeout detect-case? wait-cr? no-hints? no-hostname? long-hostname? - erase-characters kill-characters chdir delay nice extra-options) + erase-characters kill-characters chdir delay nice extra-options + shepherd-requirement) (list (shepherd-service (documentation "Run agetty on a tty.") @@ -934,7 +937,8 @@ (define agetty-shepherd-service ;; service to be done. Also wait for udev essentially so that the tty ;; text is not lost in the middle of kernel messages (see also ;; mingetty-shepherd-service). - (requirement '(user-processes host-name udev)) + (requirement (cons* 'user-processes 'host-name 'udev + shepherd-requirement)) (modules '((ice-9 match) (gnu build linux-boot))) (start From patchwork Thu Feb 3 20:55:20 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Danny Milosavljevic X-Patchwork-Id: 36963 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id F33D827BBEA; Thu, 3 Feb 2022 21:31:19 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.9 required=5.0 tests=BAYES_00,MAILING_LIST_MULTI, SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id B93E427BBE9 for ; Thu, 3 Feb 2022 21:31:19 +0000 (GMT) Received: from localhost ([::1]:40924 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nFjhG-0001RJ-Qt for patchwork@mira.cbaines.net; Thu, 03 Feb 2022 16:31:18 -0500 Received: from eggs.gnu.org ([209.51.188.92]:44924) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nFj9T-00036K-LT for guix-patches@gnu.org; Thu, 03 Feb 2022 15:56:27 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:35932) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nFj98-00015z-LH for guix-patches@gnu.org; Thu, 03 Feb 2022 15:56:20 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1nFj98-0002gm-J9 for guix-patches@gnu.org; Thu, 03 Feb 2022 15:56:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#53763] [PATCH 2/3] services: %base-services: Adapt agetty-service-type to depend on syslogd. Resent-From: dannym@scratchpost.org Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Thu, 03 Feb 2022 20:56:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 53763 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 53763@debbugs.gnu.org Cc: Danny Milosavljevic Received: via spool by 53763-submit@debbugs.gnu.org id=B53763.164392173610262 (code B ref 53763); Thu, 03 Feb 2022 20:56:02 +0000 Received: (at 53763) by debbugs.gnu.org; 3 Feb 2022 20:55:36 +0000 Received: from localhost ([127.0.0.1]:58054 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nFj8i-0002fR-0e for submit@debbugs.gnu.org; Thu, 03 Feb 2022 15:55:36 -0500 Received: from dd30410.kasserver.com ([85.13.145.193]:38788) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nFj8c-0002f7-83 for 53763@debbugs.gnu.org; Thu, 03 Feb 2022 15:55:35 -0500 Received: from dayas.lan (84-115-234-128.cable.dynamic.surfer.at [84.115.234.128]) by dd30410.kasserver.com (Postfix) with ESMTPSA id CE9A51120B23; Thu, 3 Feb 2022 21:55:28 +0100 (CET) From: dannym@scratchpost.org Date: Thu, 3 Feb 2022 21:55:20 +0100 Message-Id: <20220203205521.25145-2-dannym@scratchpost.org> X-Mailer: git-send-email 2.34.0 In-Reply-To: <20220203205521.25145-1-dannym@scratchpost.org> References: <20220203205243.25095-1-dannym@scratchpost.org> <20220203205521.25145-1-dannym@scratchpost.org> MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" X-getmail-retrieved-from-mailbox: Patches From: Danny Milosavljevic Fixes . * gnu/services/base.scm (%base-services): Reorder syslog-service for clarity. [shepherd-requirement]: New field. --- gnu/services/base.scm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/gnu/services/base.scm b/gnu/services/base.scm index d6f584abdb..028426c3f8 100644 --- a/gnu/services/base.scm +++ b/gnu/services/base.scm @@ -2787,10 +2787,12 @@ (define %base-services (cons tty %default-console-font)) '("tty1" "tty2" "tty3" "tty4" "tty5" "tty6"))) + (syslog-service) (service agetty-service-type (agetty-configuration (extra-options '("-L")) ; no carrier detect (term "vt100") - (tty #f))) ; automatic + (tty #f) ; automatic + (shepherd-requirement '(syslogd)))) (service mingetty-service-type (mingetty-configuration (tty "tty1"))) @@ -2807,7 +2809,6 @@ (define %base-services (service static-networking-service-type (list %loopback-static-networking)) - (syslog-service) (service urandom-seed-service-type) (service guix-service-type) (service nscd-service-type) From patchwork Thu Feb 3 20:55:21 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Danny Milosavljevic X-Patchwork-Id: 36964 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id B991F27BBEA; Thu, 3 Feb 2022 21:39:29 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.9 required=5.0 tests=BAYES_00,MAILING_LIST_MULTI, SPF_HELO_PASS autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 918B727BBE9 for ; Thu, 3 Feb 2022 21:39:29 +0000 (GMT) Received: from localhost ([::1]:58014 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nFjpA-0004sL-OK for patchwork@mira.cbaines.net; Thu, 03 Feb 2022 16:39:28 -0500 Received: from eggs.gnu.org ([209.51.188.92]:44922) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nFj9T-00036J-LU for guix-patches@gnu.org; Thu, 03 Feb 2022 15:56:27 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:35933) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nFj98-000160-Vn for guix-patches@gnu.org; Thu, 03 Feb 2022 15:56:20 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1nFj98-0002gt-Vb for guix-patches@gnu.org; Thu, 03 Feb 2022 15:56:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#53763] [PATCH 3/3] agetty-shepherd-service: Rename console agetty to "term-console" for clarity. Resent-From: dannym@scratchpost.org Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Thu, 03 Feb 2022 20:56:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 53763 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 53763@debbugs.gnu.org Cc: Danny Milosavljevic Received: via spool by 53763-submit@debbugs.gnu.org id=B53763.164392173710275 (code B ref 53763); Thu, 03 Feb 2022 20:56:02 +0000 Received: (at 53763) by debbugs.gnu.org; 3 Feb 2022 20:55:37 +0000 Received: from localhost ([127.0.0.1]:58057 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nFj8j-0002ff-Fa for submit@debbugs.gnu.org; Thu, 03 Feb 2022 15:55:37 -0500 Received: from dd30410.kasserver.com ([85.13.145.193]:38790) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nFj8c-0002f8-8H for 53763@debbugs.gnu.org; Thu, 03 Feb 2022 15:55:35 -0500 Received: from dayas.lan (84-115-234-128.cable.dynamic.surfer.at [84.115.234.128]) by dd30410.kasserver.com (Postfix) with ESMTPSA id 076561120D87; Thu, 3 Feb 2022 21:55:29 +0100 (CET) From: dannym@scratchpost.org Date: Thu, 3 Feb 2022 21:55:21 +0100 Message-Id: <20220203205521.25145-3-dannym@scratchpost.org> X-Mailer: git-send-email 2.34.0 In-Reply-To: <20220203205521.25145-1-dannym@scratchpost.org> References: <20220203205243.25095-1-dannym@scratchpost.org> <20220203205521.25145-1-dannym@scratchpost.org> MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" X-getmail-retrieved-from-mailbox: Patches From: Danny Milosavljevic * gnu/services/base.scm (agetty-shepherd-service)[provision]: Rename console agetty to "term-console". --- gnu/services/base.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/services/base.scm b/gnu/services/base.scm index 028426c3f8..12a3ef2e93 100644 --- a/gnu/services/base.scm +++ b/gnu/services/base.scm @@ -931,7 +931,7 @@ (define agetty-shepherd-service (list (shepherd-service (documentation "Run agetty on a tty.") - (provision (list (symbol-append 'term- (string->symbol (or tty "auto"))))) + (provision (list (symbol-append 'term- (string->symbol (or tty "console"))))) ;; Since the login prompt shows the host name, wait for the 'host-name' ;; service to be done. Also wait for udev essentially so that the tty