nix: set x-systemd options directly
Some checks failed
Test / Create distribution (push) Successful in 34s
Test / Sandbox (push) Successful in 45s
Test / Sandbox (race detector) (push) Successful in 46s
Test / Hakurei (push) Successful in 52s
Test / Hpkg (push) Successful in 50s
Test / Hakurei (race detector) (push) Successful in 54s
Test / ShareFS (push) Successful in 1m58s
Test / Flake checks (push) Failing after 1m39s
Some checks failed
Test / Create distribution (push) Successful in 34s
Test / Sandbox (push) Successful in 45s
Test / Sandbox (race detector) (push) Successful in 46s
Test / Hakurei (push) Successful in 52s
Test / Hpkg (push) Successful in 50s
Test / Hakurei (race detector) (push) Successful in 54s
Test / ShareFS (push) Successful in 1m58s
Test / Flake checks (push) Failing after 1m39s
NixOS generates two x-systemd.requires-mounts-for options for some reason, and there seems to be no knob for configuring ordering. Signed-off-by: Ophestra <cat@gensokyo.uk>
This commit is contained in:
12
nixos.nix
12
nixos.nix
@@ -25,12 +25,13 @@ let
|
|||||||
getsubname = userid: appid: "u${toString userid}_a${toString appid}";
|
getsubname = userid: appid: "u${toString userid}_a${toString appid}";
|
||||||
getsubhome = userid: appid: "${cfg.stateDir}/u${toString userid}/a${toString appid}";
|
getsubhome = userid: appid: "${cfg.stateDir}/u${toString userid}/a${toString appid}";
|
||||||
|
|
||||||
mountpoints = {
|
mountpoints = let
|
||||||
|
after = "sys-module-fuse.device";
|
||||||
|
before = "nix-daemon.socket";
|
||||||
|
in {
|
||||||
${cfg.sharefs.name} = mkIf (cfg.sharefs.source != null) {
|
${cfg.sharefs.name} = mkIf (cfg.sharefs.source != null) {
|
||||||
depends = [ cfg.sharefs.source ];
|
|
||||||
device = "sharefs";
|
device = "sharefs";
|
||||||
fsType = "fuse.sharefs";
|
fsType = "fuse.sharefs";
|
||||||
noCheck = true;
|
|
||||||
options = [
|
options = [
|
||||||
"rw"
|
"rw"
|
||||||
"noexec"
|
"noexec"
|
||||||
@@ -42,6 +43,11 @@ let
|
|||||||
"source=${cfg.sharefs.source}"
|
"source=${cfg.sharefs.source}"
|
||||||
"setuid=${toString config.users.users.${cfg.sharefs.user}.uid}"
|
"setuid=${toString config.users.users.${cfg.sharefs.user}.uid}"
|
||||||
"setgid=${toString config.users.groups.${cfg.sharefs.group}.gid}"
|
"setgid=${toString config.users.groups.${cfg.sharefs.group}.gid}"
|
||||||
|
|
||||||
|
"x-systemd.requires=${after}"
|
||||||
|
"x-systemd.before=${before}"
|
||||||
|
"x-systemd.required-by=${before}"
|
||||||
|
"x-systemd.requires-mounts-for=${cfg.sharefs.source}"
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user