Merge pull request #35 from cnsta/modulechange
refractoring modules without .enable
This commit is contained in:
@@ -15,17 +15,17 @@ in {
|
|||||||
options = {
|
options = {
|
||||||
modules.userd.sops = {
|
modules.userd.sops = {
|
||||||
enable = mkEnableOption "Enables sops home environment";
|
enable = mkEnableOption "Enables sops home environment";
|
||||||
cnst = mkOption {
|
cnst.enable = mkOption {
|
||||||
type = lib.types.bool;
|
type = lib.types.bool;
|
||||||
default = false;
|
default = false;
|
||||||
description = "Apply cnst sops settings";
|
description = "Apply cnst sops settings";
|
||||||
};
|
};
|
||||||
toothpick = mkOption {
|
toothpick.enable = mkOption {
|
||||||
type = lib.types.bool;
|
type = lib.types.bool;
|
||||||
default = false;
|
default = false;
|
||||||
description = "Apply toothpick sops settings";
|
description = "Apply toothpick sops settings";
|
||||||
};
|
};
|
||||||
adam = mkOption {
|
adam.enable = mkOption {
|
||||||
type = lib.types.bool;
|
type = lib.types.bool;
|
||||||
default = false;
|
default = false;
|
||||||
description = "Apply adam sops settings";
|
description = "Apply adam sops settings";
|
||||||
@@ -41,7 +41,7 @@ in {
|
|||||||
sshKeyPaths = [];
|
sshKeyPaths = [];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
(mkIf cfg.cnst {
|
(mkIf cfg.cnst.enable {
|
||||||
age = {sshKeyPaths = ["/home/cnst/.ssh/id_ed25519"];};
|
age = {sshKeyPaths = ["/home/cnst/.ssh/id_ed25519"];};
|
||||||
secrets = {
|
secrets = {
|
||||||
openai_api_key = {
|
openai_api_key = {
|
||||||
@@ -54,7 +54,7 @@ in {
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
})
|
})
|
||||||
(mkIf cfg.toothpick {
|
(mkIf cfg.toothpick.enable {
|
||||||
age = {sshKeyPaths = ["/home/toothpick/.ssh/id_ed25519"];};
|
age = {sshKeyPaths = ["/home/toothpick/.ssh/id_ed25519"];};
|
||||||
secrets = {
|
secrets = {
|
||||||
openai_api_key = {
|
openai_api_key = {
|
||||||
@@ -67,7 +67,7 @@ in {
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
})
|
})
|
||||||
(mkIf cfg.adam {
|
(mkIf cfg.adam.enable {
|
||||||
age = {sshKeyPaths = ["/home/adam/.ssh/id_ed25519"];};
|
age = {sshKeyPaths = ["/home/adam/.ssh/id_ed25519"];};
|
||||||
secrets = {
|
secrets = {
|
||||||
openai_api_key = {
|
openai_api_key = {
|
||||||
|
|||||||
@@ -47,7 +47,7 @@
|
|||||||
userd = {
|
userd = {
|
||||||
sops = {
|
sops = {
|
||||||
enable = true;
|
enable = true;
|
||||||
cnst = true;
|
cnst.enable = true;
|
||||||
};
|
};
|
||||||
copyq.enable = true;
|
copyq.enable = true;
|
||||||
mako.enable = true;
|
mako.enable = true;
|
||||||
|
|||||||
@@ -52,7 +52,7 @@
|
|||||||
samba.enable = false;
|
samba.enable = false;
|
||||||
sops = {
|
sops = {
|
||||||
enable = true;
|
enable = true;
|
||||||
cnix = true;
|
cnix.enable = true;
|
||||||
};
|
};
|
||||||
ssh.enable = true;
|
ssh.enable = true;
|
||||||
udisks.enable = true;
|
udisks.enable = true;
|
||||||
|
|||||||
@@ -11,17 +11,17 @@ in {
|
|||||||
options = {
|
options = {
|
||||||
modules.sysd.sops = {
|
modules.sysd.sops = {
|
||||||
enable = mkEnableOption "Enables sops system environment";
|
enable = mkEnableOption "Enables sops system environment";
|
||||||
cnix = mkOption {
|
cnix.enable = mkOption {
|
||||||
type = lib.types.bool;
|
type = lib.types.bool;
|
||||||
default = false;
|
default = false;
|
||||||
description = "Apply cnix sops settings";
|
description = "Apply cnix sops settings";
|
||||||
};
|
};
|
||||||
toothpc = mkOption {
|
toothpc.enable = mkOption {
|
||||||
type = lib.types.bool;
|
type = lib.types.bool;
|
||||||
default = false;
|
default = false;
|
||||||
description = "Apply toothpc sops settings";
|
description = "Apply toothpc sops settings";
|
||||||
};
|
};
|
||||||
adampad = mkOption {
|
adampad.enable = mkOption {
|
||||||
type = lib.types.bool;
|
type = lib.types.bool;
|
||||||
default = false;
|
default = false;
|
||||||
description = "Apply adampad sops settings";
|
description = "Apply adampad sops settings";
|
||||||
@@ -38,7 +38,7 @@ in {
|
|||||||
sshKeyPaths = [];
|
sshKeyPaths = [];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
(mkIf cfg.cnix {
|
(mkIf cfg.cnix.enable {
|
||||||
secrets = {
|
secrets = {
|
||||||
openai_api_key = {
|
openai_api_key = {
|
||||||
format = "yaml";
|
format = "yaml";
|
||||||
@@ -50,7 +50,7 @@ in {
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
})
|
})
|
||||||
(mkIf cfg.toothpc {
|
(mkIf cfg.toothpc.enable {
|
||||||
secrets = {
|
secrets = {
|
||||||
openai_api_key = {
|
openai_api_key = {
|
||||||
format = "yaml";
|
format = "yaml";
|
||||||
@@ -62,7 +62,7 @@ in {
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
})
|
})
|
||||||
(mkIf cfg.adampad {
|
(mkIf cfg.adampad.enable {
|
||||||
secrets = {
|
secrets = {
|
||||||
openai_api_key = {
|
openai_api_key = {
|
||||||
format = "yaml";
|
format = "yaml";
|
||||||
|
|||||||
Reference in New Issue
Block a user