summaryrefslogtreecommitdiff
path: root/custom/btrfs-snapshots.nix
diff options
context:
space:
mode:
Diffstat (limited to 'custom/btrfs-snapshots.nix')
-rw-r--r--custom/btrfs-snapshots.nix11
1 files changed, 3 insertions, 8 deletions
diff --git a/custom/btrfs-snapshots.nix b/custom/btrfs-snapshots.nix
index 39e0bf0c..034b5019 100644
--- a/custom/btrfs-snapshots.nix
+++ b/custom/btrfs-snapshots.nix
@@ -5,21 +5,16 @@ with lib;
5let 5let
6 cfg = config.services.btrfs-snapshots; 6 cfg = config.services.btrfs-snapshots;
7 7
8 snapshotMount = str: "${cfg.mountPoint}/${cfg.mountPrefix}${str}"; 8 snapshotMount = str: "${str}${cfg.mountSuffix}";
9in { 9in {
10 options = { 10 options = {
11 11
12 services.btrfs-snapshots = { 12 services.btrfs-snapshots = {
13 enable = mkEnableOption "a systemd unit for btrfs snapshots"; 13 enable = mkEnableOption "a systemd unit for btrfs snapshots";
14 14
15 mountPoint = mkOption { 15 mountSuffix = mkOption {
16 type = types.path;
17 default = "/mnt";
18 };
19
20 mountPrefix = mkOption {
21 type = types.str; 16 type = types.str;
22 default = "snapshot-"; 17 default = ".snapshot";
23 }; 18 };
24 19
25 readOnly = mkOption { 20 readOnly = mkOption {