fs: rename "mountpt" -> "origin" to reflect that it doesnt have to be a device
This commit is contained in:
@@ -37,7 +37,7 @@
|
||||
};
|
||||
|
||||
sane.impermanence.stores."ext" = {
|
||||
mountpt = "/mnt/impermanence/ext/persist";
|
||||
origin = "/mnt/impermanence/ext/persist";
|
||||
storeDescription = "external HDD storage";
|
||||
};
|
||||
sane.fs."/mnt/impermanence/ext".mount = {};
|
||||
|
@@ -21,7 +21,7 @@ let
|
||||
for example, a store named "private" could have description "ecnrypted to the user's password and decrypted on login".
|
||||
'';
|
||||
};
|
||||
mountpt = mkOption {
|
||||
origin = mkOption {
|
||||
type = types.str;
|
||||
};
|
||||
prefix = mkOption {
|
||||
@@ -163,7 +163,7 @@ in
|
||||
let
|
||||
store = opt.store;
|
||||
store-rel-path = path.from store.prefix opt.directory;
|
||||
backing-path = path.concat [ store.mountpt store-rel-path ];
|
||||
backing-path = path.concat [ store.origin store-rel-path ];
|
||||
|
||||
# pass through the perm/mode overrides
|
||||
dir-acl = sane-lib.filterNonNull {
|
||||
|
@@ -17,7 +17,7 @@ lib.mkIf config.sane.impermanence.enable
|
||||
stored to disk, but encrypted to an in-memory key and cleared on every boot
|
||||
so that it's unreadable after power-off
|
||||
'';
|
||||
mountpt = store.device;
|
||||
origin = store.device;
|
||||
};
|
||||
|
||||
|
||||
|
@@ -21,7 +21,7 @@ in
|
||||
# like "/var", and then "/nix/persist/var" has different perms and something mounts funny.
|
||||
# TODO: just add assertions that sane.fs."${backing}/${dest}".dir == sane.fs."${dest}" for each mount point?
|
||||
sane.fs = lib.mapAttrs' (_name: store: {
|
||||
name = "${store.mountpt}/home/colin";
|
||||
name = "${store.origin}/home/colin";
|
||||
value.dir.acl = config.sane.fs."/home/colin".generated.acl;
|
||||
}) cfg.stores;
|
||||
};
|
||||
|
@@ -4,7 +4,7 @@ let
|
||||
cfg = config.sane.impermanence;
|
||||
in lib.mkIf cfg.enable {
|
||||
sane.impermanence.stores."plaintext" = {
|
||||
mountpt = "/nix/persist";
|
||||
origin = "/nix/persist";
|
||||
};
|
||||
# TODO: needed?
|
||||
# sane.fs."/nix".mount = {};
|
||||
|
@@ -6,7 +6,7 @@ lib.mkIf config.sane.impermanence.enable
|
||||
storeDescription = ''
|
||||
encrypted to the user's password and auto-unlocked at login
|
||||
'';
|
||||
mountpt = "/home/colin/private";
|
||||
origin = "/home/colin/private";
|
||||
# files stored under here *must* have the /home/colin prefix.
|
||||
# internally, this prefix is removed so that e.g.
|
||||
# /home/colin/foo/bar when stored in `private` is visible at
|
||||
|
Reference in New Issue
Block a user