From 909f820af567d4b14519b6634433880d22fae319 Mon Sep 17 00:00:00 2001 From: Katherina Walshe-Grey Date: Mon, 9 Jun 2025 13:28:18 +0100 Subject: [PATCH] tailscale, headscale: Use internal DNS --- common/tailscale.nix | 2 ++ hosts/kalessin/default.nix | 1 - hosts/orm/default.nix | 1 - hosts/tehanu/default.nix | 1 - hosts/yevaud/default.nix | 12 ------------ services/headscale.nix | 5 ++++- 6 files changed, 6 insertions(+), 16 deletions(-) diff --git a/common/tailscale.nix b/common/tailscale.nix index 16cffcd..2614612 100644 --- a/common/tailscale.nix +++ b/common/tailscale.nix @@ -18,4 +18,6 @@ ${lib.getExe config.services.tailscale.package} up --reset ${lib.escapeShellArgs config.services.tailscale.extraUpFlags} ''; }; + + networking.domain = "birdsong.network"; } diff --git a/hosts/kalessin/default.nix b/hosts/kalessin/default.nix index 8417425..2ff3476 100644 --- a/hosts/kalessin/default.nix +++ b/hosts/kalessin/default.nix @@ -12,7 +12,6 @@ in nixpkgs.hostPlatform = "aarch64-linux"; networking.hostName = "kalessin"; networking.hostId = "534b538e"; - networking.domain = "birdsong.network"; fountain.users.qenya.enable = true; fountain.users.randomcat.enable = true; diff --git a/hosts/orm/default.nix b/hosts/orm/default.nix index ce4c125..31c990b 100644 --- a/hosts/orm/default.nix +++ b/hosts/orm/default.nix @@ -9,7 +9,6 @@ nixpkgs.hostPlatform = "x86_64-linux"; networking.hostName = "orm"; networking.hostId = "00000000"; - networking.domain = "birdsong.network"; fountain.users.qenya.enable = true; fountain.admins = [ "qenya" ]; diff --git a/hosts/tehanu/default.nix b/hosts/tehanu/default.nix index 14b4151..fc1ecad 100644 --- a/hosts/tehanu/default.nix +++ b/hosts/tehanu/default.nix @@ -9,7 +9,6 @@ nixpkgs.hostPlatform = "aarch64-linux"; networking.hostName = "tehanu"; networking.hostId = "8e1185ab"; - networking.domain = "birdsong.network"; fountain.users.qenya.enable = true; fountain.admins = [ "qenya" ]; diff --git a/hosts/yevaud/default.nix b/hosts/yevaud/default.nix index 1545c62..976f95c 100644 --- a/hosts/yevaud/default.nix +++ b/hosts/yevaud/default.nix @@ -12,7 +12,6 @@ nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; networking.hostName = "yevaud"; networking.hostId = "09673d65"; - networking.domain = "birdsong.network"; fountain.users.qenya.enable = true; fountain.admins = [ "qenya" ]; @@ -47,16 +46,5 @@ }; }; - services.nginx = { - enable = true; - virtualHosts = { - "birdsong.network" = { - forceSSL = true; - enableACME = true; - locations."/".return = "301 https://git.unspecified.systems/qenya/birdsong/"; - }; - }; - }; - system.stateVersion = "23.11"; } diff --git a/services/headscale.nix b/services/headscale.nix index eeae58c..d5f2fe9 100644 --- a/services/headscale.nix +++ b/services/headscale.nix @@ -39,7 +39,10 @@ in settings = { server_url = "https://${cfg.domain}:443"; prefixes.allocation = "random"; - dns.magic_dns = false; + dns = { + magic_dns = true; + base_domain = "birdsong.network"; + }; # disable built-in ACME client tls_cert_path = null;