about summary refs log tree commit diff
path: root/nixos/modules/services/monitoring
diff options
context:
space:
mode:
authorIvan Petkov <ivanppetkov@gmail.com>2023-12-10 11:23:37 -0800
committerIvan Petkov <ivanppetkov@gmail.com>2023-12-10 11:23:37 -0800
commitfc004b09e5fbe0affdf4cf7c12cc856dcf214849 (patch)
treee1051da5d66eef26f9a8b3212c1ad7b055f91ae7 /nixos/modules/services/monitoring
parent7d9956755e5a31d4718c949fabe786caf538fc50 (diff)
downloadnixlib-fc004b09e5fbe0affdf4cf7c12cc856dcf214849.tar
nixlib-fc004b09e5fbe0affdf4cf7c12cc856dcf214849.tar.gz
nixlib-fc004b09e5fbe0affdf4cf7c12cc856dcf214849.tar.bz2
nixlib-fc004b09e5fbe0affdf4cf7c12cc856dcf214849.tar.lz
nixlib-fc004b09e5fbe0affdf4cf7c12cc856dcf214849.tar.xz
nixlib-fc004b09e5fbe0affdf4cf7c12cc856dcf214849.tar.zst
nixlib-fc004b09e5fbe0affdf4cf7c12cc856dcf214849.zip
nixos/ups: install udev rules for nut
This is necessary to allow the usbhid driver to successfully send
commands to the attached UPS.

It is possible to work around this by explicitly using setting the user
flag (e.g. `upsdrvctl -u root shutdown`), though it is much simpler to
install the udev rules rather than patch things further.
Diffstat (limited to 'nixos/modules/services/monitoring')
-rw-r--r--nixos/modules/services/monitoring/ups.nix1
1 files changed, 1 insertions, 0 deletions
diff --git a/nixos/modules/services/monitoring/ups.nix b/nixos/modules/services/monitoring/ups.nix
index c9dda8a8c093..63afb5deb5bd 100644
--- a/nixos/modules/services/monitoring/ups.nix
+++ b/nixos/modules/services/monitoring/ups.nix
@@ -590,6 +590,7 @@ in
       "d /var/lib/nut 700"
     ];
 
+    services.udev.packages = [ pkgs.nut ];
 
 /*
     users.users.nut =