this is the dhcp6c service we want

This commit is contained in:
Daniel Barlow
2023-09-24 23:29:30 +01:00
parent 1673a71831
commit c59a228955
11 changed files with 163 additions and 60 deletions

16
modules/dhcp6c/prefix.nix Normal file
View File

@@ -0,0 +1,16 @@
{
liminix
, lib
, callPackage
}:
{ client, interface } :
let
inherit (liminix.services) longrun;
inherit (lib) mkOption types;
name = "dhcp6c.prefix.${client.name}.${interface.name}";
script = callPackage ./acquire-delegated-prefix.nix { };
in longrun {
inherit name;
run = "${script} /run/service-state/${client.name} $(output ${interface} ifname)";
dependencies = [ client interface ];
}