From 0a52c5f1b239084b8b17b487dd819868dca3d509 Mon Sep 17 00:00:00 2001 From: imxyy_soope_ Date: Sun, 4 May 2025 10:58:06 +0800 Subject: [PATCH] fix: impermanence permission --- config/hosts/imxyy-nix-server/home.nix | 5 ++++- modules/gpg.nix | 7 ++++++- modules/persist.nix | 4 ---- 3 files changed, 10 insertions(+), 6 deletions(-) diff --git a/config/hosts/imxyy-nix-server/home.nix b/config/hosts/imxyy-nix-server/home.nix index ea2b4bc..873a3db 100644 --- a/config/hosts/imxyy-nix-server/home.nix +++ b/config/hosts/imxyy-nix-server/home.nix @@ -21,7 +21,10 @@ "workspace" "Virt" - ".ssh" + { + directory = ".ssh"; + mode = "0700"; + } ".local/state" ".local/share" ".local/share/nvim" diff --git a/modules/gpg.nix b/modules/gpg.nix index 814eb66..412d556 100644 --- a/modules/gpg.nix +++ b/modules/gpg.nix @@ -14,6 +14,11 @@ lib.my.makeHomeProgramConfig { pinentryPackage = pkgs.pinentry-curses; enableSSHSupport = true; }; - my.persist.homeDirs = [ ".gnupg" ]; + my.persist.homeDirs = [ + { + directory = ".gnupg"; + mode = "0700"; + } + ]; }; } diff --git a/modules/persist.nix b/modules/persist.nix index ed1c311..a71b216 100644 --- a/modules/persist.nix +++ b/modules/persist.nix @@ -20,7 +20,6 @@ in ''; }; homeDirs = lib.mkOption { - type = with lib.types; listOf str; default = [ ]; example = lib.literalExpression '' [ @@ -33,7 +32,6 @@ in ''; }; nixosDirs = lib.mkOption { - type = with lib.types; listOf str; default = [ ]; example = lib.literalExpression '' [ @@ -46,7 +44,6 @@ in ''; }; homeFiles = lib.mkOption { - type = with lib.types; listOf str; default = [ ]; example = lib.literalExpression '' [ @@ -58,7 +55,6 @@ in ''; }; nixosFiles = lib.mkOption { - type = with lib.types; listOf str; default = [ ]; example = lib.literalExpression '' [