From patchwork Mon Oct 21 08:17:11 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Janneke Nieuwenhuizen X-Patchwork-Id: 32294 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 54FBE27BBEA; Mon, 21 Oct 2024 09:19:05 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-7.6 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_BLOCKED, RCVD_IN_VALIDITY_CERTIFIED,RCVD_IN_VALIDITY_RPBL,RCVD_IN_VALIDITY_SAFE, SPF_HELO_PASS,URIBL_BLOCKED autolearn=ham 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 1DD8727BBE2 for ; Mon, 21 Oct 2024 09:19:05 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1t2ncf-0000W4-GQ; Mon, 21 Oct 2024 04:18:41 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1t2ncd-0000Tw-Ns for guix-patches@gnu.org; Mon, 21 Oct 2024 04:18:40 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1t2ncd-0003ah-DX; Mon, 21 Oct 2024 04:18:39 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=MIME-Version:References:In-Reply-To:Date:From:To:Subject; bh=Ppe8hOhH87LBYDPktBYAQOvm/YbN/xHgkOUNWh7OPSQ=; b=G9Xuwl2iLRZ3fy/Wy/4QpgR98DiPZSDXAGE4tylCRRpMjqTDSTUZ2Oj0jL+JQmzL76CUFWg4eW/WuPibVTQEFjBUeCEV6HNmHBoEjvRDmTbRj1acXrY3ee4wCD8fBOGvJImxxlhs44Kze/wVEOhR9/GRhjjDntT/UKHUL8mXf9veQInZYJSc6xbXNT7bWMBj/PgXHPBLsqVkUk1oDYoKq66C/SDyO1UJRUcfqoTchL57ytUTuO/yBrUNKO68Am6Blb9JKPIgVrGDeGGDRyuiF/wkgALhRKKQCXhej/2feXfk+8Q9IbeR6i1gbUYiZMf7q+lbBZ/72M4h4Hc51/0h2Q==; Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1t2nd3-0003k3-JM; Mon, 21 Oct 2024 04:19:05 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#73927] [PATCH 15/16] installer: Add static-networking template. Resent-From: Janneke Nieuwenhuizen Original-Sender: "Debbugs-submit" Resent-CC: dev@jpoiret.xyz, ludo@gnu.org, othacehe@gnu.org, guix-patches@gnu.org Resent-Date: Mon, 21 Oct 2024 08:19:05 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 73927 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 73927@debbugs.gnu.org Cc: Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe X-Debbugs-Original-Xcc: Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe Received: via spool by 73927-submit@debbugs.gnu.org id=B73927.172949870114263 (code B ref 73927); Mon, 21 Oct 2024 08:19:05 +0000 Received: (at 73927) by debbugs.gnu.org; 21 Oct 2024 08:18:21 +0000 Received: from localhost ([127.0.0.1]:50039 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1t2ncK-0003hs-PS for submit@debbugs.gnu.org; Mon, 21 Oct 2024 04:18:21 -0400 Received: from eggs.gnu.org ([209.51.188.92]:36424) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1t2ncA-0003fv-6X for 73927@debbugs.gnu.org; Mon, 21 Oct 2024 04:18:10 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1t2nbe-0003Ty-Hc; Mon, 21 Oct 2024 04:17:38 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:References:In-Reply-To:Date:Subject:To: From; bh=Ppe8hOhH87LBYDPktBYAQOvm/YbN/xHgkOUNWh7OPSQ=; b=qLDaqec1vxSbJZjzZ1yk Z/W6GMBZ74b7bZCb3y5nZvVS5CRx2NkxzEbgjUyXQzc7ZTiD1hx9Rc/bkHH/9VeAJGx68b6JBzlqw Iuf3JZ5w7ftUR6CHanz+Rn7yJMwLpZ3DGZoIMMtgAE6YpU/KVbEMFOl/5C6XqHbi5Yg1RX/Zn54qT vV5UAW1XPS1wxv52KHiVaxRfE0PhmNS19A7vVVWrHS5rPH1y1to7YPu2AIHw8Ih8V4xCm7LM7oCeA WcOKQ4Oa7dcL+iee2uZWorITrXeqC+Hk+umekFZrbCp8drgOigoy8iJr1gOdPeOhPn/zKZKCN8Rn2 t0WUoTDTYoMw/Q==; From: Janneke Nieuwenhuizen Date: Mon, 21 Oct 2024 10:17:11 +0200 Message-ID: X-Mailer: git-send-email 2.46.0 In-Reply-To: References: 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-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches * gnu/installer/services.scm (%system-services): Add static-networking-service-type. Change-Id: Iec6336f8d1f49e8b801e978d5c9eeb4f83a6e748 --- gnu/installer/services.scm | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/gnu/installer/services.scm b/gnu/installer/services.scm index d5a382606c..8b117d9a20 100644 --- a/gnu/installer/services.scm +++ b/gnu/installer/services.scm @@ -149,6 +149,28 @@ (define (%system-services) (name (G_ "DHCP client (dynamic IP address assignment)")) (type 'network-management) (snippet '((service dhcp-client-service-type)))) + (system-service + (name (G_ "Static networking service.")) + (type 'network-management) + (snippet `((service + static-networking-service-type + (list %loopback-static-networking + (static-networking + (addresses + (list + (network-address + (device "eth0") + ,(comment (G_ ";; Fill-in your IP.\n")) + (value "192.168.178.10/24")))) + (routes + (list (network-route + (destination "default") + ,(comment (G_ ";; Fill-in your gateway IP.\n")) + (gateway "192.168.178.1")))) + (requirement '()) + (provision '(networking)) + ,(comment (G_ ";; Fill-in your nameservers.\n")) + (name-servers '("192.168.178.1")))))))) ;; Dealing with documents. (system-service