From mboxrd@z Thu Jan 1 00:00:00 1970 From: Julien Lepiller Subject: Re: static-networking-service Date: Sun, 16 Dec 2018 20:01:58 +0100 Message-ID: <0337824A-5453-48D4-A5C9-ECF231933B8C@lepiller.eu> References: <87d0xcp2ki.fsf@elephly.net> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:36227) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gYbu9-0006My-C5 for help-guix@gnu.org; Sun, 16 Dec 2018 14:16:48 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gYbg6-0008Ib-UH for help-guix@gnu.org; Sun, 16 Dec 2018 14:02:18 -0500 Received: from lepiller.eu ([89.234.186.109]:52900) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1gYbg5-0008GY-Bi for help-guix@gnu.org; Sun, 16 Dec 2018 14:02:13 -0500 In-Reply-To: List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-guix-bounces+gcggh-help-guix=m.gmane.org@gnu.org Sender: "Help-Guix" To: George Clemmer Cc: help-guix@gnu.org I use it like that: (service iproute2-service-type #t) You can see my complete configuration on https://lepiller=2Eeu/ma-configur= ation=2Ehtml Le 16 d=C3=A9cembre 2018 19:07:15 GMT+01:00, George Clemmer a =C3=A9crit : >Julien Lepiller writes: > >> static-networking-service is also limited to IPv4=2E I wanted to >> configure an >> IPv6 address, so I quickly wrote a service for this: > >> (define (iproute2-shepherd-service config) >> (list (shepherd-service >> (documentation "Run the iproute2 network service") >> (provision '(networking)) >> (requirement '()) >> (start #~(lambda _ >> (let ((ip (string-append #$iproute "/sbin/ip"))) >> (system* ip "a" "add" "89=2E234=2E186=2E109/32" >"dev" >> "ens18") >> (system* ip "l" "set" "ens18" "up") >> (system* ip "-6" "a" "add" >> "2a00:5884:8208::1/48" "dev" "ens18") >> (system* ip "r" "add" "89=2E234=2E186=2E1" "dev" >> "ens18") >> (system* ip "r" "add" "default" "via" >> "89=2E234=2E186=2E1" "dev" "ens18") >> (system* ip "-6" "r" "add" "default" "via" >> "fe80::204:92:100:1" "dev" "ens18")))) >> (stop #~(lambda _ >> (display "Cannot stop iproute2 service=2E\n")))))) > >Hi Julien, > >Are you actually using this? Does it simply >(static-networking-service)? > >TIA - George