summary refs log tree commit diff
path: root/gnu/services/base.scm
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2017-02-01 17:09:54 +0100
committerLudovic Courtès <ludo@gnu.org>2017-02-01 23:53:35 +0100
commit8de3e4b35f98571be39f9c0a95bfdc630ac2d266 (patch)
treea3b5c4292f34d6fc094a825b8bc4cebae98a436f /gnu/services/base.scm
parentfd05d7ecd9f021b6c52a6d27669188b44305c79d (diff)
downloadguix-8de3e4b35f98571be39f9c0a95bfdc630ac2d266.tar.gz
services: Make 'static-networking' extensible.
This allows users to statically define several interfaces.

* gnu/services/networking.scm (<static-networking>)[provision]
[name-servers]: Add default values.
(static-networking-shepherd-service)
(static-networking-etc-files)
(static-networking-shepherd-services): New procedures.
(static-networking-service-type): Change to extend both
SHEPHERD-ROOT-SERVICE-TYPE and ETC-SERVICE-TYPE.
(static-networking-service): Remove default value of #:provision.
Implement using 'simple-service'.
* gnu/services/base.scm (%base-services): Replace
'static-networking-service' call with 'service' form.
* doc/guix.texi (Networking Services): Update documentation.
Diffstat (limited to 'gnu/services/base.scm')
-rw-r--r--gnu/services/base.scm6
1 files changed, 4 insertions, 2 deletions
diff --git a/gnu/services/base.scm b/gnu/services/base.scm
index ecabf78429..d9f3a1445e 100644
--- a/gnu/services/base.scm
+++ b/gnu/services/base.scm
@@ -1546,8 +1546,10 @@ This service is not part of @var{%base-services}."
         (mingetty-service (mingetty-configuration
                            (tty "tty6")))
 
-        (static-networking-service "lo" "127.0.0.1"
-                                   #:provision '(loopback))
+        (service static-networking-service-type
+                 (list (static-networking (interface "lo")
+                                          (ip "127.0.0.1")
+                                          (provision '(loopback)))))
         (syslog-service)
         (urandom-seed-service)
         (guix-service)