From 882c42a0938bcc1855fa5aaad6dedaa642358339 Mon Sep 17 00:00:00 2001 From: Martin Berg Alstad Date: Mon, 19 May 2025 21:51:12 +0200 Subject: [PATCH] :recycle: [shared] Move domain to common file --- hosts/pi4/caddy.nix | 3 ++- shared/common.nix | 2 ++ shared/modules/security/ssh.nix | 11 ++++++++--- 3 files changed, 12 insertions(+), 4 deletions(-) diff --git a/hosts/pi4/caddy.nix b/hosts/pi4/caddy.nix index 1a52dce..50f8166 100644 --- a/hosts/pi4/caddy.nix +++ b/hosts/pi4/caddy.nix @@ -1,5 +1,6 @@ +{ common, ... }: let - domain = "martials.no"; + domain = common.domain; in { services.caddy = { diff --git a/shared/common.nix b/shared/common.nix index 5de9181..212700d 100644 --- a/shared/common.nix +++ b/shared/common.nix @@ -13,6 +13,8 @@ rec { pictures = "${dir.home}/Pictures"; }; + domain = "martials.no"; + keymaps = { layout = "gb,no"; options = "grp:alt_shift_toggle"; # Toggle using ALT + SHIFT diff --git a/shared/modules/security/ssh.nix b/shared/modules/security/ssh.nix index 88246eb..f38bf7a 100644 --- a/shared/modules/security/ssh.nix +++ b/shared/modules/security/ssh.nix @@ -1,8 +1,13 @@ -# /nix/store//etc/ssh/ssh_config -{ systemConfig, systems, ... }: +# /nix/store//etc/ssh/ssh_config & /nix/store//etc/ssh/authorized_keys +{ + systemConfig, + systems, + common, + ... +}: with builtins; let - domain = "dns.martials.no"; + domain = "dns.${common.domain}"; allSystems = systems ++ [ { hostName = "homelab";