summary refs log tree commit diff
path: root/nixos/modules/hardware
diff options
context:
space:
mode:
authorRomanos Skiadas <rom.skiad@gmail.com>2021-07-19 13:01:45 +0300
committerRomanos Skiadas <rom.skiad@gmail.com>2021-08-07 12:09:44 +0300
commit42c677174442694e5ac3c289362afa9646ba71a9 (patch)
tree3c8008979bb86d6d716a6183b083cfd717d1194f /nixos/modules/hardware
parentd00f146ca5873b323a20f9a0bc66678a4a9b6c8c (diff)
downloadnixpkgs-42c677174442694e5ac3c289362afa9646ba71a9.tar
nixpkgs-42c677174442694e5ac3c289362afa9646ba71a9.tar.gz
nixpkgs-42c677174442694e5ac3c289362afa9646ba71a9.tar.bz2
nixpkgs-42c677174442694e5ac3c289362afa9646ba71a9.tar.lz
nixpkgs-42c677174442694e5ac3c289362afa9646ba71a9.tar.xz
nixpkgs-42c677174442694e5ac3c289362afa9646ba71a9.tar.zst
nixpkgs-42c677174442694e5ac3c289362afa9646ba71a9.zip
nixos/openrazer: Change plugdev group to openrazer
For security reasons, and generally, it is best to create a more fine
grained group than plugdev. This way users that wish to tweak razer
devices don't have access to the entire plugdev group's permissions.

This is of course a breaking change.
Diffstat (limited to 'nixos/modules/hardware')
-rw-r--r--nixos/modules/hardware/openrazer.nix14
1 files changed, 9 insertions, 5 deletions
diff --git a/nixos/modules/hardware/openrazer.nix b/nixos/modules/hardware/openrazer.nix
index b5c3d674414..b4c1ddd1b33 100644
--- a/nixos/modules/hardware/openrazer.nix
+++ b/nixos/modules/hardware/openrazer.nix
@@ -49,7 +49,11 @@ in
 {
   options = {
     hardware.openrazer = {
-      enable = mkEnableOption "OpenRazer drivers and userspace daemon";
+      enable = mkEnableOption ''
+        OpenRazer drivers and userspace daemon.
+        Any users that wish to make use of the daemon need to be
+        members of the "openrazer" group.
+      '';
 
       verboseLogging = mkOption {
         type = types.bool;
@@ -106,10 +110,10 @@ in
     services.udev.packages = [ kernelPackages.openrazer ];
     services.dbus.packages = [ dbusServiceFile ];
 
-    # A user must be a member of the plugdev group in order to start
-    # the openrazer-daemon. Therefore we make sure that the plugdev
-    # group exists.
-    users.groups.plugdev = {};
+    # A user must be a member of the openrazer group in order to start
+    # the openrazer-daemon. Therefore we make sure that the group
+    # exists.
+    users.groups.openrazer = {};
 
     systemd.user.services.openrazer-daemon = {
       description = "Daemon to manage razer devices in userspace";