aboutsummaryrefslogtreecommitdiff
path: root/nix/modules/home/secrets.nix
diff options
context:
space:
mode:
authorPreston Pan <ret2pop@gmail.com>2025-01-16 00:13:06 -0800
committerPreston Pan <ret2pop@gmail.com>2025-01-16 00:13:06 -0800
commit2dff9d2b61244fed49136028d0e0f6ae3ae759cf (patch)
treeb94dabd4a159ed19705c109cd9047a724ddbd4e2 /nix/modules/home/secrets.nix
parentdd461e48043dabee4694e2b200f4c1d9cfdbc3d9 (diff)
modules about done
Diffstat (limited to 'nix/modules/home/secrets.nix')
-rw-r--r--nix/modules/home/secrets.nix29
1 files changed, 14 insertions, 15 deletions
diff --git a/nix/modules/home/secrets.nix b/nix/modules/home/secrets.nix
index 64eab73..d24129c 100644
--- a/nix/modules/home/secrets.nix
+++ b/nix/modules/home/secrets.nix
@@ -1,19 +1,18 @@
-{ lib, config, pkgs, inputs, ... }:
+{ config, ... }:
{
- imports = [
- ../vars.nix
- ];
-
- options = {
- secrets.enable = lib.mkEnableOption "enables encrypted secrets on system";
+ defaultSopsFile = ../../secrets/secrets.yaml;
+ age = {
+ keyFile = "/home/${config.vars.userName}/.ssh/keys.txt";
};
-
- config = lib.mkIf config.secrets.enable {
- home-manager = {
- sharedModules = [
- inputs.sops-nix.homeManagerModules.sops
- ];
- users."${user.user}" = {};
- };
+ secrets.mail = {
+ format = "yaml";
+ path = "${config.sops.defaultSymlinkPath}/mail";
};
+ secrets.digikey = {
+ format = "yaml";
+ path = "${config.sops.defaultSymlinkPath}/digikey";
+ };
+
+ defaultSymlinkPath = "/run/user/1000/secrets";
+ defaultSecretsMountPoint = "/run/user/1000/secrets.d";
}