nixos treewide: don't set MODULE_DIR

This commit is contained in:
Nikolay Amiantov 2016-08-14 13:01:14 +03:00
parent b2ebecd9e5
commit 1f63958772
8 changed files with 1 additions and 17 deletions

View File

@ -75,7 +75,6 @@ in
serviceConfig = {
ExecStart = "${bumblebee}/bin/bumblebeed --use-syslog -g ${cfg.group} --driver ${cfg.driver}";
};
environment.MODULE_DIR="/run/current-system/kernel-modules/lib/modules/";
};
};
}

View File

@ -36,7 +36,6 @@ in
# and load it back on resume
powerManagement.resumeCommands = ''
export MODULE_DIR=/run/current-system/kernel-modules/lib/modules
${pkgs.kmod}/bin/modprobe -v facetimehd
'';

View File

@ -72,8 +72,6 @@ in
ExecStart = "${tlp}/bin/tlp init start";
ExecStop = "${tlp}/bin/tlp init stop";
};
environment.MODULE_DIR="/run/current-system/kernel-modules/lib/modules/";
};
tlp-sleep = {
@ -92,8 +90,6 @@ in
ExecStart = "${tlp}/bin/tlp suspend";
ExecStop = "${tlp}/bin/tlp resume";
};
environment.MODULE_DIR="/run/current-system/kernel-modules/lib/modules/";
};
};

View File

@ -316,8 +316,7 @@ in
'';
systemd.services.systemd-udevd =
{ environment.MODULE_DIR = "/run/booted-system/kernel-modules/lib/modules";
restartTriggers = cfg.packages;
{ restartTriggers = cfg.packages;
};
};

View File

@ -228,7 +228,6 @@ in
systemd.services."systemd-modules-load" =
{ wantedBy = [ "multi-user.target" ];
restartTriggers = [ kernelModulesConf ];
environment.MODULE_DIR = "/run/booted-system/kernel-modules/lib/modules";
serviceConfig =
{ # Ignore failed module loads. Typically some of the
# modules in boot.kernelModules are "nice to have but
@ -238,10 +237,6 @@ in
};
};
systemd.services.kmod-static-nodes =
{ environment.MODULE_DIR = "/run/booted-system/kernel-modules/lib/modules";
};
lib.kernelConfig = {
isYes = option: {
assertion = config: config.isYes option;

View File

@ -63,8 +63,6 @@ with lib;
echo ${pkgs.kmod}/bin/modprobe > /proc/sys/kernel/modprobe
'';
environment.sessionVariables.MODULE_DIR = "/run/current-system/kernel-modules/lib/modules";
};
}

View File

@ -207,6 +207,5 @@ exec {logOutFd}>&- {logErrFd}>&-
# Start systemd.
echo "starting systemd..."
PATH=/run/current-system/systemd/lib/systemd \
MODULE_DIR=/run/booted-system/kernel-modules/lib/modules \
LOCALE_ARCHIVE=/run/current-system/sw/lib/locale/locale-archive \
exec systemd

View File

@ -96,7 +96,6 @@ in
} // proxy_env;
path = [ pkgs.kmod ] ++ (optional (cfg.storageDriver == "zfs") pkgs.zfs);
environment.MODULE_DIR = "/run/current-system/kernel-modules/lib/modules";
postStart = if cfg.socketActivation then "" else cfg.postStart;