From c038ddc461efc5bf0bf0120469dbad2e344a6fe6 Mon Sep 17 00:00:00 2001 From: Thomas Boerger Date: Sun, 24 Nov 2024 16:31:08 +0100 Subject: [PATCH] fix: try to make check happy again --- flake.nix | 46 +++++++++++++++++++++++++++++++--- machines/asgard/default.nix | 6 +++++ machines/utgard/default.nix | 6 +++++ machines/vanaheim/default.nix | 6 +++++ machines/yggdrasil/default.nix | 6 +++++ profiles/thomas/default.nix | 6 +++++ shared/global/default.nix | 1 - shared/global/nixpkgs.nix | 43 ------------------------------- 8 files changed, 73 insertions(+), 47 deletions(-) delete mode 100644 shared/global/nixpkgs.nix diff --git a/flake.nix b/flake.nix index a71acee..d04d435 100644 --- a/flake.nix +++ b/flake.nix @@ -42,6 +42,45 @@ let inherit (self) outputs; + sharedConfiguration = { config, pkgs, ... }: { + nix = { + package = pkgs.nixVersions.stable; + + extraOptions = '' + experimental-features = nix-command flakes + ''; + + settings = { + substituters = [ + "https://cache.nixos.org" + "https://nix-community.cachix.org" + "https://nixpkgs.cachix.org" + "https://tboerger.cachix.org" + ]; + + trusted-public-keys = [ + "cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY=" + "nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs=" + "nixpkgs.cachix.org-1:q91R6hxbwFvDqTSDKwDAV4T5PxqXGxswD8vhONFMeOE=" + "tboerger.cachix.org-1:3Q1gyqgA9NsOshOgknDvc6fhA8gw0PFAf2qs5vJpeLU=" + ]; + }; + + gc = { + automatic = true; + persistent = true; + dates = "weekly"; + options = "--delete-older-than 2w"; + }; + }; + + nixpkgs = { + config = { + allowUnfree = true; + }; + }; + }; + mkComputer = configurationNix: systemName: extraModules: nixpkgs.lib.nixosSystem { system = systemName; @@ -55,6 +94,7 @@ }; } ) + sharedConfiguration homemanager.nixosModules.home-manager agenix.nixosModules.default configurationNix @@ -90,7 +130,7 @@ users = { thomas = { imports = [ - # agenix.homeManagerModules.default + agenix.homeManagerModules.default ./profiles/thomas ]; }; @@ -115,7 +155,7 @@ users = { thomas = { imports = [ - # agenix.homeManagerModules.default + agenix.homeManagerModules.default ./profiles/thomas ]; }; @@ -140,7 +180,7 @@ users = { thomas = { imports = [ - # agenix.homeManagerModules.default + agenix.homeManagerModules.default ./profiles/thomas ]; }; diff --git a/machines/asgard/default.nix b/machines/asgard/default.nix index 828b226..b419246 100644 --- a/machines/asgard/default.nix +++ b/machines/asgard/default.nix @@ -13,6 +13,12 @@ ./extras.nix ]; + age = { + identityPaths = [ + "/etc/ssh/ssh_host_ed25519_key" + ]; + }; + personal = { services = { shares = { diff --git a/machines/utgard/default.nix b/machines/utgard/default.nix index c26a0f8..d1496de 100644 --- a/machines/utgard/default.nix +++ b/machines/utgard/default.nix @@ -13,6 +13,12 @@ ./extras.nix ]; + age = { + identityPaths = [ + "/etc/ssh/ssh_host_ed25519_key" + ]; + }; + personal = { services = { hass = { diff --git a/machines/vanaheim/default.nix b/machines/vanaheim/default.nix index f7c98cd..91c2b93 100644 --- a/machines/vanaheim/default.nix +++ b/machines/vanaheim/default.nix @@ -13,6 +13,12 @@ ./extras.nix ]; + age = { + identityPaths = [ + "/etc/ssh/ssh_host_ed25519_key" + ]; + }; + personal = { services = { cloud = { diff --git a/machines/yggdrasil/default.nix b/machines/yggdrasil/default.nix index f542242..03fc968 100644 --- a/machines/yggdrasil/default.nix +++ b/machines/yggdrasil/default.nix @@ -13,6 +13,12 @@ ./extras.nix ]; + age = { + identityPaths = [ + "/etc/ssh/ssh_host_ed25519_key" + ]; + }; + personal = { services = { homedns = { diff --git a/profiles/thomas/default.nix b/profiles/thomas/default.nix index 52f7a63..0d3e0ce 100644 --- a/profiles/thomas/default.nix +++ b/profiles/thomas/default.nix @@ -20,6 +20,12 @@ in ./services ]; + age = { + identityPaths = [ + "${config.home.homeDirectory}/.ssh/id_ed25519" + ]; + }; + profile = { desktop = { gnome = { diff --git a/shared/global/default.nix b/shared/global/default.nix index 826783a..da8ae2e 100644 --- a/shared/global/default.nix +++ b/shared/global/default.nix @@ -5,7 +5,6 @@ ./general.nix ./haveged.nix ./network.nix - ./nixpkgs.nix ./openssh.nix ./shells.nix ./sudo.nix diff --git a/shared/global/nixpkgs.nix b/shared/global/nixpkgs.nix deleted file mode 100644 index e0fe466..0000000 --- a/shared/global/nixpkgs.nix +++ /dev/null @@ -1,43 +0,0 @@ -{ pkgs, lib, config, options, ... }: -with lib; - -{ - config = { - nix = { - package = pkgs.nixVersions.stable; - - extraOptions = '' - experimental-features = nix-command flakes - ''; - - settings = { - substituters = [ - "https://cache.nixos.org" - "https://nix-community.cachix.org" - "https://nixpkgs.cachix.org" - "https://tboerger.cachix.org" - ]; - - trusted-public-keys = [ - "cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY=" - "nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs=" - "nixpkgs.cachix.org-1:q91R6hxbwFvDqTSDKwDAV4T5PxqXGxswD8vhONFMeOE=" - "tboerger.cachix.org-1:3Q1gyqgA9NsOshOgknDvc6fhA8gw0PFAf2qs5vJpeLU=" - ]; - }; - - gc = { - automatic = true; - persistent = true; - dates = "weekly"; - options = "--delete-older-than 2w"; - }; - }; - - nixpkgs = { - config = { - allowUnfree = true; - }; - }; - }; -}