From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2.migadu.com ([2001:41d0:403:4876::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms13.migadu.com with LMTPS id AC1aD4TOQ2eZnQAAe85BDQ:P1 (envelope-from ) for ; Mon, 25 Nov 2024 01:10:28 +0000 Received: from aspmx1.migadu.com ([2001:41d0:403:4876::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2.migadu.com with LMTPS id AC1aD4TOQ2eZnQAAe85BDQ (envelope-from ) for ; Mon, 25 Nov 2024 02:10:28 +0100 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=debbugs.gnu.org header.s=debbugs-gnu-org header.b=RPWwVFHe; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20230601 header.b="X/LNExAF"; dmarc=fail reason="SPF not aligned (relaxed), DKIM not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" ARC-Seal: i=1; s=key1; d=yhetil.org; t=1732497028; a=rsa-sha256; cv=none; b=LWLOUMyCRG48r7Bcr++IOjzATdVe9zzjNYv87aTGQ2H9ibTk4PDh5+269NVUapEHByJRI8 nGXvGIwuBcF0WC6hTuCs0lHraj/dcS9iuyg70QleOG+9gYcrVx+244ytl2QBiBf6GmbxTN 3PBg9JEkhrY9wu3VVi6GJu0ddMw86bvaJDazUY0d+HDf486B2UK6ywhTP0D7nAd2T6VezG TVmaLWNGIJDrPlOHqrAgs2CgxVu+rQ8dfwC0Pfc9Om/qVASALz1ix6sOaUWRe4IiZsy9EA jxJk645EA7ak8znrYQfj091Rsxsu5NSB4rHwU1j7nGoExZCrE3tNv//ITBgMxg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=debbugs.gnu.org header.s=debbugs-gnu-org header.b=RPWwVFHe; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20230601 header.b="X/LNExAF"; dmarc=fail reason="SPF not aligned (relaxed), DKIM not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1732497028; 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: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=o13DBrS0o4sFFsol0SMjThGdsuAiaA/2a43Z/iXaWs0=; b=UUe9iza/WRAH+EvNSdk+DK0um5GnF1hTxsaO7m+80xtFxAjuUQAHxtQ7JKW6mKNVJdj60D Iy/Kk0tp9aErSZzbIC3Ft7CcxtpN1aLqEyLcl2bwtUn9AvDSIvjsKrskjC5sHiHsD9Ga4w TPGOmZk2/3hZruc4QYghtstjm/EL3NbCtxcR+qOQR5DKw72iLKUk6HE4T/AUL2TQ5SobAk CrrE0refkTtxB2PH8mwj/TTlsd3+HjfuYmWJExhXxVMjNwRU4sYy3uX2JBuPRJxTfABeF+ 2K+2+Diyj6mc63gcbaA+Kft/JYuzmWCTWf2wByb+rutecj/Xjl1Z5Z1VaIiNSg== 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 069E982EFE for ; Mon, 25 Nov 2024 02:10:26 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tFNc6-0007lf-OH; Sun, 24 Nov 2024 20:10:06 -0500 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 1tFNc4-0007k7-Kj for guix-patches@gnu.org; Sun, 24 Nov 2024 20:10:04 -0500 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 1tFNc2-0007fq-9D for guix-patches@gnu.org; Sun, 24 Nov 2024 20:10:04 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=MIME-Version:Date:References:In-Reply-To:From:To:Subject; bh=o13DBrS0o4sFFsol0SMjThGdsuAiaA/2a43Z/iXaWs0=; b=RPWwVFHez9Mbi68JtuzOJm6iVg2PN8bLCHpiHIbGJx3B27jBfdpwWQdjUZaNse2BE64Vqp9zmRfY9TGLbGn7DBu7xq19krQh7Ul4uDFLDS/Mrqrb6PcacJrZruljjEW+o7JDeqfTM4sxP8cg/26YPA2DrXLb8qDEvwIgLulg/zQbdfrlc8Be6Pec+/dlgHCdYjuWcvcC7EfRLfF/g8WqyK72twr4/gFkMN7jJWOt8upDdTltaEySmkGU5yEEQeYIW3th53z+MYrUvYjsDMs81V6i0Q8gV8MHzDRWomOurGcasxXc41fdeHh3Mme2u9P1oJwiPdwlcVPazGCWkvKO7w==; Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1tFNc2-0006IB-55 for guix-patches@gnu.org; Sun, 24 Nov 2024 20:10:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#74510] [PATCH] doc: Document the (possible) need for network-online for NFS. Resent-From: Maxim Cournoyer Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 25 Nov 2024 01:10:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 74510 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Tomas Volf <~@wolfsden.cz> Cc: Ludovic =?UTF-8?Q?Court=C3=A8s?= , 74510@debbugs.gnu.org Received: via spool by 74510-submit@debbugs.gnu.org id=B74510.173249698024146 (code B ref 74510); Mon, 25 Nov 2024 01:10:02 +0000 Received: (at 74510) by debbugs.gnu.org; 25 Nov 2024 01:09:40 +0000 Received: from localhost ([127.0.0.1]:36587 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tFNbf-0006HN-Ez for submit@debbugs.gnu.org; Sun, 24 Nov 2024 20:09:39 -0500 Received: from mail-pf1-f172.google.com ([209.85.210.172]:46484) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tFNbc-0006HF-Tt for 74510@debbugs.gnu.org; Sun, 24 Nov 2024 20:09:38 -0500 Received: by mail-pf1-f172.google.com with SMTP id d2e1a72fcca58-724f1ce1732so1032487b3a.1 for <74510@debbugs.gnu.org>; Sun, 24 Nov 2024 17:09:36 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1732496916; x=1733101716; darn=debbugs.gnu.org; h=mime-version:user-agent:message-id:date:references:in-reply-to :subject:cc:to:from:from:to:cc:subject:date:message-id:reply-to; bh=o13DBrS0o4sFFsol0SMjThGdsuAiaA/2a43Z/iXaWs0=; b=X/LNExAFWIeg8HEtBmblE9J6n2sYyqe9SJbA5ZREH5By49p2f/IRtvYiy2pkOG9wea v7s1CyT34ZcN6hSBpDgcUf0Aa5BgZtsAOFmaDleGZD0LZYyoRO3X9RwypjYcfAwx1fPj YDyqe5gksVmm5EGmXAvoZAzLBw5ADmabnyy9S93MjbiPsC5a9tH1p4lGq1XvyFJCJts3 5vUbyqPB6m8R8zWKOXYACr34U5vTtNFDLXFfu0eLfpBQgC6vSzyTK4MoHx205aQhCc0W 7sopPmz+Eqxuc72ZMBxonOjVQv06wabXkhfmzP70JvstWpz3nXDm9hBZoHopmMuC0HrO jhww== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1732496916; x=1733101716; h=mime-version:user-agent:message-id:date:references:in-reply-to :subject:cc:to:from:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=o13DBrS0o4sFFsol0SMjThGdsuAiaA/2a43Z/iXaWs0=; b=xSIz2K4E6cFqhRnp4Le5TQ2+DDp2C5RY2CS5kORgcqW5jDB4QtGAF6q4nFCkhXj4yU 1/hsWYW4Qq9ya68MA+MDLgzFRu07NYCqUaXjb0DpF5BA6tu6U7GUJJ0QeESabEpbLBCA dY6/omBHI5sahD/uYfUUwy1pRxe1ctF+mb7vKqvSOleey1Nt5rtge1DzFcua4rlqyCIe Ns2Uaw/j3dgJx9x6HnXoGCe8Z7uxTFpsl71uGk8hG5FTJ/rhYYi7kxW/9ALzuXxPuSuv YFjrpYfFGHOgy+eHFvvcc1XniKG0YGURMuq5bEEKX83ZvK+9TAkqojVrZwtcX2lvX4cc CZTw== X-Gm-Message-State: AOJu0Yy+pfp7lsm+oOXNUXsk6e00gu2YV1LDQTQCzJbaLXC+E8wor0to OuMSPy8fubzbGqhRWOPcdgBbPbOScZO8ppOhpsmnnYrlmuNLvsMdFe+EJ4Ms X-Gm-Gg: ASbGncsZANj3jGeJGvH/86Q34mi7ndGBFcsqhi5KxcccCnnuzLxymHeocjqgoaZwWVm bskB2hXypMd+dT9l/8MbG5fXsT8m9XRlouvbNAxOTQwaWhKlimrxxi7cnbqg9KI3ooLm4JyibtD +S0IzsVWoqRJ6KEMvgpcLaDqAw/0aC2ZQ/eHcSrBuEu13Cf2d6VPvoCNVZJ7s5/tFyx0K0YyTGR Yph93AXLsJP0nWLrHN9PTrEvJA74PAQ+yBJIikCvd1B1Hg= X-Google-Smtp-Source: AGHT+IEGS0xSaFBmiG3+6CUnxcZfyd44MkOwY5MOXKnkGml1dMB34i3UKQ0dSW2P4SdeuSjb8HgDYw== X-Received: by 2002:a17:90b:4a51:b0:2ea:4e67:5638 with SMTP id 98e67ed59e1d1-2eb0e884761mr14401134a91.35.1732496916043; Sun, 24 Nov 2024 17:08:36 -0800 (PST) Received: from terra ([2405:6586:be0:0:c8ff:1707:9b9:af89]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-2eb0d048c5fsm5454793a91.37.2024.11.24.17.08.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 24 Nov 2024 17:08:35 -0800 (PST) From: Maxim Cournoyer In-Reply-To: <2e43b85dce9d86ded76acc7acee234847c49a616.1732470232.git.~@wolfsden.cz> (Tomas Volf's message of "Sun, 24 Nov 2024 18:43:52 +0100") References: <2e43b85dce9d86ded76acc7acee234847c49a616.1732470232.git.~@wolfsden.cz> Date: Mon, 25 Nov 2024 10:08:26 +0900 Message-ID: <87o724nmr9.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain 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-bounces+larch=yhetil.org@gnu.org X-Migadu-Country: US X-Migadu-Flow: FLOW_IN X-Migadu-Spam-Score: -3.39 X-Spam-Score: -3.39 X-Migadu-Queue-Id: 069E982EFE X-Migadu-Scanner: mx10.migadu.com X-TUID: qav91bccOzRA Hi Tomas, Tomas Volf <~@wolfsden.cz> writes: > Depending on networking is not enough in some setups, so a language clarifying > that and an example of network-online service. > > * doc/guix.texi (File Systems): Document the possible need for network-online. > > Change-Id: I8abe07cc9d6dc61f28eeea7ffa785eb8c9e8fd09 > --- > doc/guix.texi | 28 +++++++++++++++++++++++++++- > 1 file changed, 27 insertions(+), 1 deletion(-) > > diff --git a/doc/guix.texi b/doc/guix.texi > index 26488b41c8..861e78e6d2 100644 > --- a/doc/guix.texi > +++ b/doc/guix.texi > @@ -18018,7 +18018,33 @@ File Systems > met before mounting the file system. > > As an example, an NFS file system would typically have a requirement for > -@code{networking}. > +@code{networking}. However be aware that depending on @code{networking} > +might not be sufficient in some setups and a variant of custom > +@code{network-online} service might be necessary. Could we be more precise and detail a simple case or example of when requiring 'network-online is needed over just 'network for NFS? > Example: > + > +@lisp > +(simple-service 'network-online shepherd-root-service-type > + (list > + (shepherd-service > + (requirement '(networking)) > + (provision '(network-online)) > + (documentation "Wait for the network to come up.") > + (start #~(lambda _ > + (let* ((cmd > + "set -eux > +c=0 > +while ! /run/setuid-programs/ping -qc1 -W1 example.org; do > + sleep 1 > + [ \"$((c += 1))\" -lt 30 ] || exit 1 # Limit the wait time > +done > +") > + (status (system cmd))) > + (= 0 (status:exit-val status))))) I'm pretty sure we have connectivity tests already in the Guix test suite that must make use of Guile; that would be nicer, I think; for example, the (guix tests) module has: --8<---------------cut here---------------start------------->8--- (define (network-reachable?) "Return true if we can reach the Internet." (false-if-exception (getaddrinfo "www.gnu.org" "80" AI_NUMERICSERV))) --8<---------------cut here---------------end--------------->8--- > + ;; Ordering for one-shot? services does not currently work. > + ;; https://issues.guix.gnu.org/74284 > + ;; (one-shot? #t) > + ))) > +@end lisp Otherwise, it looks like a useful addition. -- Thanks, Maxim