diff --git a/nix/configuration/configuration.nix b/nix/configuration/configuration.nix index 638a728..a2d6aec 100644 --- a/nix/configuration/configuration.nix +++ b/nix/configuration/configuration.nix @@ -49,6 +49,7 @@ ./roles/steam ./roles/latex ./roles/launch_keyboard + ./roles/lvfs ./roles/nvme ]; diff --git a/nix/configuration/roles/lvfs/default.nix b/nix/configuration/roles/lvfs/default.nix new file mode 100644 index 0000000..9514b3d --- /dev/null +++ b/nix/configuration/roles/lvfs/default.nix @@ -0,0 +1,33 @@ +{ + config, + lib, + pkgs, + ... +}: + +{ + imports = [ ]; + + config = lib.mkMerge [ + { + services.fwupd.enable = true; + + environment.persistence."/persist" = lib.mkIf (!config.me.buildingIso) { + hideMounts = true; + directories = [ + { + directory = "/var/lib/fwupd"; + user = "root"; + group = "root"; + mode = "0755"; + } + ]; + }; + } + (lib.mkIf config.me.graphical { + environment.systemPackages = with pkgs; [ + gnome-firmware + ]; + }) + ]; +}