From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0 ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id cDElB+1rfGFBvwAAgWs5BA (envelope-from ) for ; Fri, 29 Oct 2021 23:47:25 +0200 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0 with LMTPS id aDHcAu1rfGEdOwAA1q6Kng (envelope-from ) for ; Fri, 29 Oct 2021 21:47:25 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id C9C2DDC01 for ; Fri, 29 Oct 2021 23:47:24 +0200 (CEST) Received: from localhost ([::1]:43658 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mgZid-0001BS-SG for larch@yhetil.org; Fri, 29 Oct 2021 17:47:23 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:60080) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mgZfP-00022W-7R for guix-patches@gnu.org; Fri, 29 Oct 2021 17:44:03 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:44638) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mgZfN-0008Iy-T6 for guix-patches@gnu.org; Fri, 29 Oct 2021 17:44:01 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mgZfN-0006Tt-Pd for guix-patches@gnu.org; Fri, 29 Oct 2021 17:44:01 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#51440] [PATCH 00/10] Declarative static networking interface Resent-From: Ludovic =?UTF-8?Q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Fri, 29 Oct 2021 21:44:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 51440 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Julien Lepiller Cc: 51440@debbugs.gnu.org Received: via spool by 51440-submit@debbugs.gnu.org id=B51440.163554379224819 (code B ref 51440); Fri, 29 Oct 2021 21:44:01 +0000 Received: (at 51440) by debbugs.gnu.org; 29 Oct 2021 21:43:12 +0000 Received: from localhost ([127.0.0.1]:56181 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mgZeZ-0006SF-Oh for submit@debbugs.gnu.org; Fri, 29 Oct 2021 17:43:12 -0400 Received: from eggs.gnu.org ([209.51.188.92]:34358) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mgZeY-0006Rx-Dr for 51440@debbugs.gnu.org; Fri, 29 Oct 2021 17:43:10 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:59300) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mgZeT-0008EE-1L; Fri, 29 Oct 2021 17:43:05 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:In-Reply-To:Date:References:Subject:To: From; bh=U14/aO7qWkZSAjCqVGtoR6BCbiXr7T05aa0K30grMV4=; b=OWz5fPpQmUHt0uJ4Fyot dZNbeu/G8TH0Hv5CFHQcuLzBO43wdugtKX39DclKsfcW+Rao2PfUNsi2F17JGWGlACD8kz1yJxD0J oTgA+dQ2XG1GZWHfOqK3XYV1U1IfoqvuYET4YgdSXxjgvn/l1AD8SBpXnEKTO15MTuTE7tbFG0WbP 4L+3W5qbAr4V58d6Pwiqds8rcefMOhjyXXWbtiwn6JVc8H/hV17tbGlUX+hshlCw/OdNcfugHrYqk ynfmGm0PSHT0XYZB4gRB5gXt8f8VQwXFpZsYNfubW6l/d2fjOnoEz9oe6G/X1J3Qi5Gf+EvOn3KoI GIBED2vw09zcYw==; Received: from 91-160-117-201.subs.proxad.net ([91.160.117.201]:55470 helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mgZeS-0003Jg-Gz; Fri, 29 Oct 2021 17:43:04 -0400 From: Ludovic =?UTF-8?Q?Court=C3=A8s?= References: <20211027140245.18970-1-ludo@gnu.org> <20211027140245.18970-7-ludo@gnu.org> <20211028031738.50dc8114@tachikoma.lepiller.eu> Date: Fri, 29 Oct 2021 23:43:02 +0200 In-Reply-To: <20211028031738.50dc8114@tachikoma.lepiller.eu> (Julien Lepiller's message of "Thu, 28 Oct 2021 03:17:38 +0200") Message-ID: <87zgqrwlqx.fsf_-_@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable 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+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1635544044; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:resent-cc: resent-from:resent-sender:resent-message-id:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=U14/aO7qWkZSAjCqVGtoR6BCbiXr7T05aa0K30grMV4=; b=h9Ftv08SAb9G6JAZwatLkd5lJcO26w60P0x7CmAwY8YerNls6bsEZMqch0yOm3546h96Cb Adpa2Eb3a+e1omLKM9UTEyTxxpWw8BpAr/S8XZqIyhatFFd2ZK8ZXvqQhGhZ/RNwzRnPj0 oJmeZh9EQDDGGJqqFBCc6T7YX/zXPLgPY3qN3B/HOg2hETW72JeiTH75QunHaRLuN0PUsy sXj0y2Z0CDE7ehHACsu7wmiVbxTzioQgf7i+uCml8ia1I4n1eX+7xVKKlDywrrjJjuya+x 09sAU7qlfF83DBqTzojrm/dWVgxJSrPfF4k+amMhnJSiCd5fEzaHsYpTRIupvw== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1635544044; a=rsa-sha256; cv=none; b=fQVfPFkCAMXon0wCLZVLo4g7Ua4LAJxKf0JM1trll0nBQFc5N88c2cnnGQoNst2q1D15vs OXS8m6b2YWrh6ecH3K8sx4Pqf2+csKNPVigAMfJGs5KYme02YN/agmtWJ9smdkFwOvaB/N CJ53hPtvf4IW0A+rKHNpht1nUSikr8kKmRTyFXqJG5C9XvkchiKmSbE8s7Y3Zo9SrTW9Kf RbMxk/6S1Aqn6VmExjzPhSVEtmN5s+WGExzM0SYsQF/695gN+KTsN+opyFp5Ok61sZZhiV tL8sAeGPQeuq41BZ6sgsDe8KiBeo24+7ySBolSL1H5CUBClLIis/kFIUjk7LKA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gnu.org header.s=fencepost-gnu-org header.b=OWz5fPpQ; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Spam-Score: -2.92 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gnu.org header.s=fencepost-gnu-org header.b=OWz5fPpQ; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Queue-Id: C9C2DDC01 X-Spam-Score: -2.92 X-Migadu-Scanner: scn0.migadu.com X-TUID: f0ts+6La52p2 Hi! Julien Lepiller skribis: > A few comments on the documentation below. > > Le Wed, 27 Oct 2021 16:02:42 +0200, > Ludovic Court=C3=A8s a =C3=A9crit : > >> @lisp >> -(static-networking-service "eno1" "192.168.1.82" >> - #:gateway "192.168.1.2" >> - #:name-servers '("192.168.1.2")) >> +;; Network configuration for one NIC, IPv4 + IPv6. >> +(static-networking >> + (addresses (list (network-address >> + (device "eno1") >> + (value "10.0.2.15/24")) >> + (network-address >> + (device "eno1") >> + (value "2001:123:4567:101::1")))) >> + (routes (list (network-route >> + (destination "default") >> + (gateway "10.0.2.2")) >> + (network-route >> + (destination "default") >> + (gateway "2020:321:4567:42::1")))) >> + (name-servers '("10.0.2.3"))) >> @end lisp > > I don't know if you tested that, but I think this is not routable > because the IPv6 network doesn't have a netmask, so I think it defaults > to a /128 (one IP in the network), so the router is not on the local > network. Many ISPs provide a /64 (when the provide IPv6), so maybe use > that as the netmask? No I didn=E2=80=99t test it, so yes: let=E2=80=99s add /64 above. >> +ip address add 10.0.2.15/24 dev eno1 >> +ip address add 2001:123:4567:101::1 dev eno1 >> +ip route add default via inet 10.0.2.2 >> +ip route add default via inet6 2020:321:4567:42::1 >> +@end example > > And so, change it here too. Yes. >> +Run @command{man 8 ip} for more info. Venerable GNU/Linux users will >> +certainly know how to do it with @command{ifconfig} and >> @command{route}, +but we'll spare you that. >> + >> +The available fields of this data type are as follows: >> + >> +@table @asis >> +@item @code{addresses} >> +@itemx @code{links} (default: @code{'()}) >> +@itemx @code{links} (default: @code{'()}) > > One of them should be routes, right? Oops, yes. >> +@item @code{provision} (default: @code{#f}) >> +If true, this should be a list of symbols for the Shepherd service >> +corresponding to this network configuration. When @code{#f}, >> +@code{'(networking)} or @code{'(loopback)} is used. > > Under which conditions is it 'loopback instead of 'networking? Hmm that part is wrong: #f is equivalent to (networking) in practice. I=E2=80=99ll fix that. > The rest of the manual changes look good :) You mentioned on IRC veth pairs as an example use of links. Could you formalize it for inclusion as an example? Thanks for the careful review! Ludo=E2=80=99.