From 390bdaaf51b97194f5aa68ab47bcfe9b4eb90525 Mon Sep 17 00:00:00 2001 From: Jake Hillion Date: Sat, 9 Nov 2024 19:07:33 +0000 Subject: [PATCH] resilio: update to unstable module Currently this pins `rslsync`'s group ID using https://github.com/NixOS/nixpkgs/pull/350055 --- hosts/phoenix.st.ts.hillion.co.uk/default.nix | 2 +- modules/impermanence.nix | 4 ++++ modules/resilio.nix | 5 ++++- 3 files changed, 9 insertions(+), 2 deletions(-) diff --git a/hosts/phoenix.st.ts.hillion.co.uk/default.nix b/hosts/phoenix.st.ts.hillion.co.uk/default.nix index 8f03d4d..1316f7e 100644 --- a/hosts/phoenix.st.ts.hillion.co.uk/default.nix +++ b/hosts/phoenix.st.ts.hillion.co.uk/default.nix @@ -90,7 +90,7 @@ in in builtins.map (mkFolder) folderNames; }; - services.resilio.directoryRoot = "/${zpool_name}/users/jake/sync"; + services.resilio.directoryRoot = "/${zpool_name}/sync"; ## Chia age.secrets."chia/farmer.key" = { diff --git a/modules/impermanence.nix b/modules/impermanence.nix index 4ee27cb..f5ce19b 100644 --- a/modules/impermanence.nix +++ b/modules/impermanence.nix @@ -50,6 +50,10 @@ in path = lib.mkOverride 999 "/data/chia"; }; + services.resilio = lib.mkIf config.services.resilio.enable { + directoryRoot = lib.mkOverride 999 "${cfg.base}/sync"; + }; + services.plex = lib.mkIf config.services.plex.enable { dataDir = lib.mkOverride 999 "/data/plex"; }; diff --git a/modules/resilio.nix b/modules/resilio.nix index 9a1bf48..380012e 100644 --- a/modules/resilio.nix +++ b/modules/resilio.nix @@ -1,9 +1,12 @@ -{ pkgs, lib, config, ... }: +{ pkgs, lib, config, nixpkgs-unstable, ... }: let cfg = config.custom.resilio; in { + imports = [ "${nixpkgs-unstable}/nixos/modules/services/networking/resilio.nix" ]; + disabledModules = [ "services/networking/resilio.nix" ]; + options.custom.resilio = { enable = lib.mkEnableOption "resilio";