This commit is contained in:
mjallen18
2025-07-28 11:06:32 -05:00
parent 5ae3f1a9ef
commit 6f5e592d8c
22 changed files with 95 additions and 106 deletions

View File

@@ -1,10 +1,12 @@
{ config, lib, ... }:
let
user = "matt";
defaultSops = (lib.snowfall.fs.get-file "secrets/pi4-secrets.yaml");
sharedSops = (lib.snowfall.fs.get-file "secrets/secrets.yaml");
in
{
sops = {
defaultSopsFile = lib.mkForce ../../../secrets/pi4-secrets.yaml;
defaultSopsFile = lib.mkForce defaultSops;
# age = {
# generateKey = true;
# sshKeyPaths = [ "/etc/ssd/ssh_host_ed25519_key" ];
@@ -16,7 +18,7 @@ in
# ------------------------------
secrets = {
"wifi" = {
sopsFile = ../../../secrets/secrets.yaml;
sopsFile = sharedSops;
};
"pi4/matt-password" = {
neededForUsers = true;
@@ -30,21 +32,21 @@ in
# ------------------------------
"ssh-keys-public/pi4" = {
sopsFile = ../../../secrets/secrets.yaml;
sopsFile = sharedSops;
mode = "0644";
owner = config.users.users."${user}".name;
group = config.users.users."${user}".group;
restartUnits = [ "sshd.service" ];
};
"ssh-keys-private/pi4" = {
sopsFile = ../../../secrets/secrets.yaml;
sopsFile = sharedSops;
mode = "0600";
owner = config.users.users."${user}".name;
group = config.users.users."${user}".group;
restartUnits = [ "sshd.service" ];
};
"ssh-keys-public/pi5" = {
sopsFile = ../../../secrets/secrets.yaml;
sopsFile = sharedSops;
neededForUsers = true;
mode = "0600";
owner = config.users.users.root.name;

View File

@@ -1,10 +1,12 @@
{ config, lib, ... }:
let
user = "matt";
defaultSops = (lib.snowfall.fs.get-file "secrets/pi5-secrets.yaml");
sharedSops = (lib.snowfall.fs.get-file "secrets/secrets.yaml");
in
{
sops = {
defaultSopsFile = lib.mkForce ../../../secrets/pi5-secrets.yaml;
defaultSopsFile = lib.mkForce defaultSops;
# age.sshKeyPaths = [ "/etc/ssh/ssh_host_ed25519_key" ];
age.keyFile = "/home/matt/.config/sops/age/keys.txt";
@@ -13,7 +15,7 @@ in
# ------------------------------
secrets = {
"wifi" = {
sopsFile = ../../../secrets/secrets.yaml;
sopsFile = sharedSops;
};
"pi5/matt-password" = {
neededForUsers = true;
@@ -27,14 +29,14 @@ in
# ------------------------------
"ssh-keys-public/pi5" = {
sopsFile = ../../../secrets/secrets.yaml;
sopsFile = sharedSops;
mode = "0644";
owner = config.users.users."${user}".name;
group = config.users.users."${user}".group;
restartUnits = [ "sshd.service" ];
};
"ssh-keys-private/pi5" = {
sopsFile = ../../../secrets/secrets.yaml;
sopsFile = sharedSops;
mode = "0600";
owner = config.users.users."${user}".name;
group = config.users.users."${user}".group;