liminix

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | README | LICENSE

primary.nix (268B)


      1 {
      2   liminix,
      3   lib,
      4 }:
      5 { ifname }:
      6 let
      7   inherit (liminix.services) oneshot;
      8 in
      9 oneshot rec {
     10   name = "${ifname}.link";
     11   up = ''
     12     ip link add name ${ifname} type bridge
     13     ${liminix.networking.ifup name ifname}
     14   '';
     15   down = "ip link set down dev ${ifname}";
     16 }