nix/nixos/hosts/nixos-framework/syncthing.nix

40 lines
1.4 KiB
Nix
Raw Normal View History

2024-02-13 14:03:41 +01:00
{ pkgs, config, hostname, username, ... }: {
2024-02-13 14:10:40 +01:00
imports = [ ../../common/services/syncthing.nix ];
2024-02-13 14:59:46 +01:00
# Set up the secrets file:
sops.secrets."syncthing-cert" = {
2024-02-13 15:00:15 +01:00
owner = "root";
2024-02-13 14:59:46 +01:00
sopsFile = ../../../secrets/hosts/nixos-framework.yaml;
restartUnits = [ "syncthing.service" ];
};
sops.secrets."syncthing-key" = {
2024-02-13 15:00:15 +01:00
owner = "root";
2024-02-13 14:59:46 +01:00
sopsFile = ../../../secrets/hosts/nixos-framework.yaml;
restartUnits = [ "syncthing.service" ];
};
2024-02-13 14:03:41 +01:00
services.syncthing = {
enable = true;
2024-02-13 14:59:46 +01:00
cert = "/run/secrets/syncthing-cert";
key = "/run/secrets/syncthing-key";
2024-02-13 14:20:05 +01:00
user = "${username}";
2024-02-13 14:59:46 +01:00
configDir = "/home/${username}/.config/syncthing";
2024-02-13 14:36:09 +01:00
overrideDevices = true;
overrideFolders = true;
2024-02-13 14:03:41 +01:00
settings = {
folders = {
2024-03-09 16:24:37 +01:00
"kenshi-saves" = {
id = "kenshi";
path = "/home/${username}/.steam/steam/steamapps/compatdata/233860/pfx/drive_c/users/steamuser/AppData/Local/kenshi/";
devices = [ "framework-server" "win10-desktop" ];
};
2024-02-13 14:03:41 +01:00
"world-of-warcraft" = {
id = "ergcw-ay6yg";
2024-02-13 14:03:47 +01:00
path = "/home/${username}/Games/battlenet/drive_c/Program Files (x86)/World of Warcraft/";
2024-03-09 16:24:37 +01:00
devices = [ "framework-server" "win10-desktop" ];
2024-02-13 14:03:41 +01:00
};
};
};
};
2024-03-09 16:24:37 +01:00
}