diff --git a/machines/rigel/networking.nix b/machines/rigel/networking.nix index 1db8413..bc73880 100644 --- a/machines/rigel/networking.nix +++ b/machines/rigel/networking.nix @@ -13,6 +13,12 @@ in prefixLength = 24; } ]; + ipv6.addresses = [ + { + address = "fdab:c002:36cb::1"; + prefixLength = 64; + } + ]; }; }; @@ -25,69 +31,29 @@ in "1.1.1.1" "8.8.8.8" ]; + # enable-ra = true; domain-needed = true; domain = "localhost"; - dhcp-range = [ "192.168.254.10,192.168.254.240,255.255.255.0,24h" ]; + dhcp-range = [ + "192.168.254.10,192.168.254.240,255.255.255.0,24h" + "fdab:c002:36cb::10,fdab:c002:36cb::240,slaac" + ]; dhcp-option = [ "3,192.168.254.1" "6,8.8.8.8,8.8.4.4" + "option6:information-refresh-time,3600" ]; interface = [ ata-interface ]; }; }; - services.traefik = { + services.nginx = { enable = true; - staticConfigOptions = { - # log.level = "DEBUG"; - log = { - level = "DEBUG"; - filePath = "/data/traefik/traefik.log"; - }; - - serversTransport.insecureSkipVerify = true; - - entryPoints = { - web = { - address = ":80"; - transport.respondingTimeouts = { - readTimeout = "3600s"; - writeTimeout = "0"; - idleTimeout = "300s"; - }; + virtualHosts = { + "_" = { + locations."/" = { + proxyPass = "http://192.168.254.96"; }; - websecure = { - address = ":443"; - transport.respondingTimeouts = { - readTimeout = "3600s"; - writeTimeout = "0"; - idleTimeout = "300s"; - }; - }; - }; - global = { - checkNewVersion = false; - sendAnonymousUsage = false; - }; - }; - dynamicConfigOptions = { - http.middlewares = { - redirect-to-https.redirectscheme = { - scheme = "https"; - permanent = true; - }; - redirect-to-www.redirectregex = { - permanent = true; - regex = "^https?://(?:www\\.)?(.+)"; - replacement = "https://www.\${1}"; - }; - }; - http = { - routers.ata-web = { - rule = ""; - service = "ata-web"; - }; - services.ata-web.loadBalancer.servers = [ { url = "http://192.168.254.96"; } ]; }; }; };