summaryrefslogtreecommitdiffstats
path: root/makefu/1systems/gum/config.nix
diff options
context:
space:
mode:
authortv <tv@krebsco.de>2017-08-24 17:39:53 +0200
committertv <tv@krebsco.de>2017-08-24 17:39:53 +0200
commitfd69096a27575b9d4d87a10af1492b273dad167c (patch)
treeaa3e7dc121d3188a16a37a6751ec774abcc0df81 /makefu/1systems/gum/config.nix
parentb9a4e834c06bc32fa38389e13c0ec42467c0fc46 (diff)
parentfd6b42355907de5313ea3576e5d1bfa549433099 (diff)
Merge remote-tracking branch 'prism/master'
Diffstat (limited to 'makefu/1systems/gum/config.nix')
-rw-r--r--makefu/1systems/gum/config.nix24
1 files changed, 14 insertions, 10 deletions
diff --git a/makefu/1systems/gum/config.nix b/makefu/1systems/gum/config.nix
index bbb8cfe11..110edc130 100644
--- a/makefu/1systems/gum/config.nix
+++ b/makefu/1systems/gum/config.nix
@@ -9,6 +9,7 @@ let
external-gw6 = "fe80::1";
external-netmask = 22;
external-netmask6 = 64;
+ ext-if = "et0"; # gets renamed on the fly
internal-ip = config.krebs.build.host.nets.retiolum.ip4.addr;
main-disk = "/dev/disk/by-id/scsi-0QEMU_QEMU_HARDDISK_drive-scsi0-0-0-0";
in {
@@ -41,6 +42,7 @@ in {
<stockholm/makefu/2configs/sabnzbd.nix>
<stockholm/makefu/2configs/torrent.nix>
<stockholm/makefu/2configs/iodined.nix>
+ <stockholm/makefu/2configs/vpn/openvpn-server.nix>
## Web
<stockholm/makefu/2configs/nginx/share-download.nix>
@@ -94,7 +96,7 @@ in {
];
};
-
+ makefu.server.primary-itf = ext-if;
# access
users.users = {
@@ -120,7 +122,7 @@ in {
# Network
services.udev.extraRules = ''
- SUBSYSTEM=="net", ATTR{address}=="${external-mac}", NAME="et0"
+ SUBSYSTEM=="net", ATTR{address}=="${external-mac}", NAME="${ext-if}"
'';
boot.kernelParams = [ ];
networking = {
@@ -152,14 +154,16 @@ in {
21032
];
};
- interfaces.et0.ip4 = [{
- address = external-ip;
- prefixLength = external-netmask;
- }];
- interfaces.et0.ip6 = [{
- address = external-ip6;
- prefixLength = external-netmask6;
- }];
+ interfaces."${ext-if}" = {
+ ip4 = [{
+ address = external-ip;
+ prefixLength = external-netmask;
+ }];
+ ip6 = [{
+ address = external-ip6;
+ prefixLength = external-netmask6;
+ }];
+ };
defaultGateway6 = external-gw6;
defaultGateway = external-gw;
nameservers = [ "8.8.8.8" ];