From fb055f309d1c67307ace07af69a01f362ada561a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Thalheim?= Date: Mon, 2 Dec 2024 09:22:56 +0100 Subject: [PATCH] {darwin,home-manager}: add example template --- checks/darwin.nix | 8 +++++++- checks/home-manager.nix | 7 +++++-- 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/checks/darwin.nix b/checks/darwin.nix index 8b74e33..fe67b43 100644 --- a/checks/darwin.nix +++ b/checks/darwin.nix @@ -1,10 +1,16 @@ - +{ + config, + ... +}: { imports = [ ../modules/nix-darwin/default.nix ]; documentation.enable = false; sops.secrets.test_key = { }; + sops.templates."template.toml".content = '' + password = "${config.sops.placeholder.test_key}"; + ''; sops.defaultSopsFile = ../pkgs/sops-install-secrets/test-assets/secrets.yaml; sops.age.generateKey = true; system.stateVersion = 5; diff --git a/checks/home-manager.nix b/checks/home-manager.nix index d1e6355..3c32fd6 100644 --- a/checks/home-manager.nix +++ b/checks/home-manager.nix @@ -1,5 +1,5 @@ - -{ config, ... }: { +{ config, ... }: +{ imports = [ ../modules/home-manager/sops.nix ]; @@ -11,5 +11,8 @@ sops.age.generateKey = true; sops.age.keyFile = "${config.home.homeDirectory}/.age-key.txt"; sops.secrets.test_key = { }; + sops.templates."template.toml".content = '' + password = "${config.sops.placeholder.test_key}"; + ''; sops.defaultSopsFile = ../pkgs/sops-install-secrets/test-assets/secrets.yaml; }