Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions nixos/modules/services/hardware/udev.nix
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,13 @@ let
preferLocalBuild = true;
allowSubstitutes = false;
packages = lib.unique (map toString udevPackages);

nativeBuildInputs = [
# We only include the out output here to avoid needing to include all
# other outputs in the installer tests as well
# We only need the udevadm command anyway
pkgs.systemdMinimal.out
];
}
''
mkdir -p $out
Expand Down Expand Up @@ -147,6 +154,11 @@ let
exit 1
fi

# Verify all the udev rules
echo "Verifying udev rules using udevadm verify..."
udevadm verify --resolve-names=never --no-style $out
echo "OK"

# If auto-configuration is disabled, then remove
# udev's 80-drivers.rules file, which contains rules for
# automatically calling modprobe.
Expand Down
7 changes: 6 additions & 1 deletion nixos/tests/installer.nix
Original file line number Diff line number Diff line change
Expand Up @@ -681,7 +681,7 @@ let
{
# The configuration of the system used to run "nixos-install".
installer =
{ config, ... }:
{ config, pkgs, ... }:
{
imports = [
commonConfig
Expand Down Expand Up @@ -740,6 +740,11 @@ let
xorg.lndir
shellcheck-minimal

# Only the out output is included here, which is what is
# required to build the NixOS udev rules
# See the comment in services/hardware/udev.nix
systemdMinimal.out

# add curl so that rather than seeing the test attempt to download
# curl's tarball, we see what it's trying to download
curl
Expand Down