From e6b171f9f1d975ffe34e7a34743b5e92e8593847 Mon Sep 17 00:00:00 2001 From: Akshay Nair Date: Wed, 11 Jun 2025 13:57:24 +0530 Subject: Add service router + nsd server --- configuration.nix | 21 +++++++++++++++++++-- 1 file changed, 19 insertions(+), 2 deletions(-) (limited to 'configuration.nix') diff --git a/configuration.nix b/configuration.nix index 45b34ab..048164f 100644 --- a/configuration.nix +++ b/configuration.nix @@ -2,8 +2,12 @@ # your system. Help is available in the configuration.nix(5) man page # and in the NixOS manual (accessible by running ‘nixos-help’). -{ pkgs, ... }: - +{ pkgs, lib, ... }: +let + settings = import ./settings.nix { inherit lib; }; + ports = settings.network.ports; + host = settings.network.host; +in { imports = [ ./modules/hardware.nix @@ -11,8 +15,20 @@ ./modules/network ./modules/media ./modules/dashboard + ./modules/service-router.service.nix ]; + services.service-router = { + enable = true; + routes = { + "home.local" = { inherit host; port = ports.dashboard; }; + "sonarr.local" = { inherit host; port = ports.sonarr; }; + "radarr.local" = { inherit host; port = ports.radarr; }; + "prowlarr.local" = { inherit host; port = ports.prowlarr; }; + "jellyfin.local" = { inherit host; port = ports.jellyfin; }; + }; + }; + nixpkgs.config.allowUnfree = true; environment.systemPackages = with pkgs; [ @@ -21,6 +37,7 @@ neovim lf util-linux + dig ]; systemd.extraConfig = ''DefaultLimitNOFILE=65536''; -- cgit v1.3.1