refactor
This commit is contained in:
@@ -4,6 +4,8 @@
|
||||
...
|
||||
}: {
|
||||
imports = [
|
||||
./secrets.nix
|
||||
./syncthing.nix
|
||||
../../modules/syncthing.nix
|
||||
../../profiles/core.nix
|
||||
../../profiles/darwin.nix
|
||||
@@ -17,32 +19,6 @@
|
||||
networking.hostName = "jason";
|
||||
networking.computerName = "Jason";
|
||||
|
||||
services.syncthing.settings.folders = {
|
||||
"Projects/Personal" = {
|
||||
path = "/Users/${user}/Projects/Personal";
|
||||
devices = ["tahani" "jason"];
|
||||
};
|
||||
};
|
||||
|
||||
sops.age.keyFile = "/Users/${user}/.config/sops/age/keys.txt";
|
||||
sops.age.sshKeyPaths = [];
|
||||
sops.gnupg.sshKeyPaths = [];
|
||||
|
||||
sops.secrets = {
|
||||
jason-syncthing-cert = {
|
||||
sopsFile = ../../secrets/jason-syncthing-cert;
|
||||
format = "binary";
|
||||
owner = user;
|
||||
path = "/Users/${user}/.config/syncthing/cert.pem";
|
||||
};
|
||||
jason-syncthing-key = {
|
||||
sopsFile = ../../secrets/jason-syncthing-key;
|
||||
format = "binary";
|
||||
owner = user;
|
||||
path = "/Users/${user}/.config/syncthing/key.pem";
|
||||
};
|
||||
};
|
||||
|
||||
home-manager.users.${user} = {
|
||||
imports = [
|
||||
inputs.nixvim.homeModules.nixvim
|
||||
|
||||
20
hosts/jason/secrets.nix
Normal file
20
hosts/jason/secrets.nix
Normal file
@@ -0,0 +1,20 @@
|
||||
{user, ...}: {
|
||||
sops.age.keyFile = "/Users/${user}/.config/sops/age/keys.txt";
|
||||
sops.age.sshKeyPaths = [];
|
||||
sops.gnupg.sshKeyPaths = [];
|
||||
|
||||
sops.secrets = {
|
||||
jason-syncthing-cert = {
|
||||
sopsFile = ../../secrets/jason-syncthing-cert;
|
||||
format = "binary";
|
||||
owner = user;
|
||||
path = "/Users/${user}/.config/syncthing/cert.pem";
|
||||
};
|
||||
jason-syncthing-key = {
|
||||
sopsFile = ../../secrets/jason-syncthing-key;
|
||||
format = "binary";
|
||||
owner = user;
|
||||
path = "/Users/${user}/.config/syncthing/key.pem";
|
||||
};
|
||||
};
|
||||
}
|
||||
8
hosts/jason/syncthing.nix
Normal file
8
hosts/jason/syncthing.nix
Normal file
@@ -0,0 +1,8 @@
|
||||
{user, ...}: {
|
||||
services.syncthing.settings.folders = {
|
||||
"Projects/Personal" = {
|
||||
path = "/Users/${user}/Projects/Personal";
|
||||
devices = ["tahani" "jason"];
|
||||
};
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user