builders: do not mount / and /boot on netboot systems
This commit is contained in:
parent
f7907a2915
commit
830dcbf6bc
|
@ -55,29 +55,34 @@ in
|
||||||
|
|
||||||
boot.initrd.services.lvm.enable = true;
|
boot.initrd.services.lvm.enable = true;
|
||||||
|
|
||||||
fileSystems."/" = {
|
boot.kernel.sysctl."fs.xfs.xfssyncd_centisecs" = "12000";
|
||||||
|
fileSystems = lib.mkMerge [
|
||||||
|
{
|
||||||
|
"/" = {
|
||||||
device = "/dev/disk/by-label/root";
|
device = "/dev/disk/by-label/root";
|
||||||
fsType = "xfs";
|
fsType = "xfs";
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/mnt" = {
|
"/boot" = {
|
||||||
device = "/dev/disk/by-label/hydra";
|
|
||||||
fsType = "xfs";
|
|
||||||
options = ["logbsize=256k"];
|
|
||||||
};
|
|
||||||
boot.kernel.sysctl."fs.xfs.xfssyncd_centisecs" = "12000";
|
|
||||||
|
|
||||||
# We want the tmp filesystem on the same filesystem as the hydra store, so that builds can use reflinks
|
|
||||||
fileSystems."/tmp" = {
|
|
||||||
device = "/mnt/tmp";
|
|
||||||
options = [ "bind" ];
|
|
||||||
};
|
|
||||||
|
|
||||||
fileSystems."/boot" = {
|
|
||||||
device = "/dev/disk/by-label/BOOT";
|
device = "/dev/disk/by-label/BOOT";
|
||||||
fsType = "vfat";
|
fsType = "vfat";
|
||||||
options = [ "fmask=0022" "dmask=0022" ];
|
options = [ "fmask=0022" "dmask=0022" ];
|
||||||
};
|
};
|
||||||
|
}
|
||||||
|
(lib.mkIf (!cfg.netboot) {
|
||||||
|
"/mnt" = {
|
||||||
|
device = "/dev/disk/by-label/hydra";
|
||||||
|
fsType = "xfs";
|
||||||
|
options = ["logbsize=256k"];
|
||||||
|
};
|
||||||
|
|
||||||
|
# We want the tmp filesystem on the same filesystem as the hydra store, so that builds can use reflinks
|
||||||
|
"/tmp" = {
|
||||||
|
device = "/mnt/tmp";
|
||||||
|
options = [ "bind" ];
|
||||||
|
};
|
||||||
|
})
|
||||||
|
];
|
||||||
|
|
||||||
swapDevices = lib.optionals (!cfg.netboot) [
|
swapDevices = lib.optionals (!cfg.netboot) [
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue