unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
From: Alexey Abramov via Guix-patches via <guix-patches@gnu.org>
To: 64850@debbugs.gnu.org
Subject: [bug#64850] [PATCH 1/1] services: dhcp-client-configuration: Allow provision override
Date: Tue, 25 Jul 2023 12:59:56 +0200	[thread overview]
Message-ID: <20230725105956.17963-1-levenson@mmer.org> (raw)
In-Reply-To: <20230725105739.17244-1-levenson@mmer.org>

* gnu/services/networking.scm: Allow setting up provision to allow running
DHCP client and static network configuration simultaneously.
---
 gnu/services/networking.scm | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/gnu/services/networking.scm b/gnu/services/networking.scm
index 5657b141d9..dc75c2f59d 100644
--- a/gnu/services/networking.scm
+++ b/gnu/services/networking.scm
@@ -88,6 +88,7 @@ (define-module (gnu services networking)
             dhcp-client-configuration
             dhcp-client-configuration?
             dhcp-client-configuration-package
+            dhcp-client-configuration-provision
             dhcp-client-configuration-interfaces
             dhcp-client-configuration-shepherd-requirement
 
@@ -303,6 +304,8 @@ (define-record-type* <dhcp-client-configuration>
                 (default isc-dhcp))
   (shepherd-requirement dhcp-client-configuration-shepherd-requirement
                         (default '()))
+  (provision    dhcp-client-configuration-provision
+                (default '(networking)))
   (interfaces   dhcp-client-configuration-interfaces
                 (default 'all)))                  ;'all | list of strings
 
@@ -312,6 +315,7 @@ (define dhcp-client-shepherd-service
      (let ((package (dhcp-client-configuration-package config))
            (shepherd-requirement (dhcp-client-configuration-shepherd-requirement config))
            (interfaces (dhcp-client-configuration-interfaces config))
+           (provision (dhcp-client-configuration-provision config))
            (pid-file "/var/run/dhclient.pid"))
        (list (shepherd-service
               (documentation "Set up networking via DHCP.")
@@ -321,7 +325,7 @@ (define dhcp-client-shepherd-service
               ;; networking is unavailable, but also means that the interface is not up
               ;; yet when 'start' completes.  To wait for the interface to be ready, one
               ;; should instead monitor udev events.
-              (provision '(networking))
+              (provision provision)
 
               (start #~(lambda _
                          (define dhclient
-- 
2.40.1





  reply	other threads:[~2023-07-25 11:01 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-07-25 10:57 [bug#64850] [PATCH 0/1] Provide a way to use multiple dhcp clients with static-networking Alexey Abramov via Guix-patches via
2023-07-25 10:59 ` Alexey Abramov via Guix-patches via [this message]
2023-09-17 13:06   ` bug#64850: " Ludovic Courtès

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230725105956.17963-1-levenson@mmer.org \
    --to=guix-patches@gnu.org \
    --cc=64850@debbugs.gnu.org \
    --cc=levenson@mmer.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).