feat(nixosModules/server): add autoMounting helios

This commit is contained in:
Mohammad Rafiq 2025-05-29 16:28:31 +08:00
parent 91ba03dfba
commit 591c90db68
No known key found for this signature in database
3 changed files with 15 additions and 0 deletions

View file

@ -1,6 +1,7 @@
{ lib, config, ... }: { lib, config, ... }:
{ {
options.server = { options.server = {
mountHelios = lib.mkEnableOption "";
enableDDNS = lib.mkEnableOption ""; enableDDNS = lib.mkEnableOption "";
}; };
@ -53,5 +54,16 @@
}; };
}; };
}) })
(lib.mkIf config.server.mountHelios {
fileSystems."/media/helios/data" = {
device = "//helios/data";
fsType = "cifs";
options = [
"x-systemd.automount"
"x-systemd.requires=tailscaled.service"
"x-systemd.mount-timeout=0"
];
};
})
]; ];
} }

View file

@ -22,6 +22,7 @@
server = { server = {
enableDDNS = true; enableDDNS = true;
mountHelios = true;
}; };
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";

View file

@ -35,5 +35,7 @@
enableVR = true; enableVR = true;
enableSunshine = true; enableSunshine = true;
}; };
server.mountHelios = true;
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
} }