prep: setup sops demo for otf
This commit is contained in:
parent
1254657679
commit
3196a30c4d
3 changed files with 18 additions and 3 deletions
|
|
@ -1,6 +1,11 @@
|
||||||
# See /modules/nixos/* for actual settings
|
# See /modules/nixos/* for actual settings
|
||||||
# This file is just *top-level* configuration.
|
# This file is just *top-level* configuration.
|
||||||
{ flake, modulesPath, ... }:
|
{
|
||||||
|
flake,
|
||||||
|
modulesPath,
|
||||||
|
config,
|
||||||
|
...
|
||||||
|
}:
|
||||||
|
|
||||||
let
|
let
|
||||||
inherit (flake) inputs;
|
inherit (flake) inputs;
|
||||||
|
|
@ -15,6 +20,7 @@ in
|
||||||
tty-ips.enable = true;
|
tty-ips.enable = true;
|
||||||
otf = {
|
otf = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
environmentFile = config.sops.secrets.otfenv.path;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
networking = {
|
networking = {
|
||||||
|
|
|
||||||
|
|
@ -19,7 +19,7 @@ in
|
||||||
};
|
};
|
||||||
package = lib.mkPackageOption pkgs "otf" { };
|
package = lib.mkPackageOption pkgs "otf" { };
|
||||||
pgPackage = lib.mkPackageOption pkgs "postgresql_16" { };
|
pgPackage = lib.mkPackageOption pkgs "postgresql_16" { };
|
||||||
environmentFile = lib.mkEnableOption {
|
environmentFile = lib.mkOption {
|
||||||
type = with lib.types; nullOr path;
|
type = with lib.types; nullOr path;
|
||||||
default = lib.types.null;
|
default = lib.types.null;
|
||||||
};
|
};
|
||||||
|
|
|
||||||
|
|
@ -9,5 +9,14 @@
|
||||||
imports = [
|
imports = [
|
||||||
flake.inputs.sops-nix.nixosModules.sops
|
flake.inputs.sops-nix.nixosModules.sops
|
||||||
];
|
];
|
||||||
sops.defaultSopsFile = ../../../secrets.yaml;
|
sops = {
|
||||||
|
defaultSopsFile = ../../../secrets.yaml;
|
||||||
|
secrets = {
|
||||||
|
otfenv = {
|
||||||
|
owner = "otf";
|
||||||
|
group = "otf";
|
||||||
|
mode = "0440";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue