From 0d8c62f7b347966ca545dd77528a31780b94f792 Mon Sep 17 00:00:00 2001 From: Gregor Kleen Date: Sun, 24 Nov 2019 18:50:14 +0100 Subject: refactor borgbackup --- custom/lvm-snapshots.nix | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'custom/lvm-snapshots.nix') diff --git a/custom/lvm-snapshots.nix b/custom/lvm-snapshots.nix index 98c64330..13cbf421 100644 --- a/custom/lvm-snapshots.nix +++ b/custom/lvm-snapshots.nix @@ -7,7 +7,7 @@ let cfg = config.services.lvm-snapshots; snapshotMount = name: "${cfg.mountPoint}/${if isNull cfg.snapshots."${name}".mountName then name else cfg.snapshots."${name}".mountName}"; - snapshotName = name: "${name}-snapshot"; + snapshotName = name: "${name}-${cfg.mountSuffix}"; snapshotConfig = { options = { @@ -53,6 +53,11 @@ in { type = types.path; default = "/mnt"; }; + + mountSuffix = mkOption { + type = types.str; + default = "-snapshot"; + }; }; }; -- cgit v1.2.3