diff options
Diffstat (limited to 'custom')
| -rw-r--r-- | custom/tinc/yggdrasil.nix | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/custom/tinc/yggdrasil.nix b/custom/tinc/yggdrasil.nix index 2e5a2442..46d815a3 100644 --- a/custom/tinc/yggdrasil.nix +++ b/custom/tinc/yggdrasil.nix | |||
| @@ -19,19 +19,21 @@ with stdenv.lib; | |||
| 19 | ${optionalString connect "ConnectTo = ymir"} | 19 | ${optionalString connect "ConnectTo = ymir"} |
| 20 | ''; | 20 | ''; |
| 21 | scripts = { | 21 | scripts = { |
| 22 | tinc-up = '' | 22 | "hosts/borealis-up" = '' |
| 23 | #!${stdenv.shell} | 23 | #!${stdenv.shell} |
| 24 | ${nettools}/bin/route add -net 10.141.1.0 netmask 255.255.255.0 gw 10.141.1.1 dev $INTERFACE metric 9999 | 24 | ${nettools}/bin/route add -net 10.141.1.0 netmask 255.255.255.0 gw 10.141.1.1 dev $INTERFACE metric 9999 |
| 25 | ${optionalString useDNS '' | 25 | ${optionalString useDNS '' |
| 26 | ${openresolv}/bin/resolvconf -m 0 -a tinc.yggdrasil <<EOF | 26 | ${openresolv}/bin/resolvconf -m 0 -a tinc.yggdrasil <<EOF |
| 27 | domain yggdrasil | 27 | domain yggdrasil |
| 28 | nameserver 10.141.1.1 | 28 | nameserver 10.141.1.1 |
| 29 | EOF''} | 29 | EOF |
| 30 | ''} | ||
| 30 | ''; | 31 | ''; |
| 31 | tinc-down = '' | 32 | "hosts/borealis-down" = '' |
| 32 | #!${stdenv.shell} | 33 | #!${stdenv.shell} |
| 34 | ${nettools}/bin/route del -net 10.141.1.0 netmask 255.255.255.0 gw 10.141.1.1 dev $INTERFACE | ||
| 33 | ${optionalString useDNS '' | 35 | ${optionalString useDNS '' |
| 34 | ${openresolv}/bin/resolvconf -d tinc.yggdrasil | 36 | ${openresolv}/bin/resolvconf -d tinc.yggdrasil |
| 35 | ''} | 37 | ''} |
| 36 | ''; | 38 | ''; |
| 37 | }; | 39 | }; |
