From b138b7e8e8c5f6fe316d197b8b133a1054ea9677 Mon Sep 17 00:00:00 2001 From: Guanran Wang Date: Wed, 7 Feb 2024 09:51:49 +0800 Subject: [PATCH] hosts: per-device anti-feature --- .../core => hosts/Aristotle}/anti-feature.nix | 29 ++++--------------- hosts/Aristotle/default.nix | 1 + nixos/profiles/common/core/default.nix | 1 - 3 files changed, 7 insertions(+), 24 deletions(-) rename {nixos/profiles/common/core => hosts/Aristotle}/anti-feature.nix (54%) diff --git a/nixos/profiles/common/core/anti-feature.nix b/hosts/Aristotle/anti-feature.nix similarity index 54% rename from nixos/profiles/common/core/anti-feature.nix rename to hosts/Aristotle/anti-feature.nix index b7f93f6..34a757c 100644 --- a/nixos/profiles/common/core/anti-feature.nix +++ b/hosts/Aristotle/anti-feature.nix @@ -1,43 +1,26 @@ {lib, ...}: { - hardware.enableRedistributableFirmware = true; - #hardware.enableAllFirmware = true; - nixpkgs.config = { - allowBroken = false; - allowUnsupportedSystem = false; - allowNonSource = false; allowNonSourcePredicate = pkg: builtins.elem (lib.getName pkg) [ - "vscodium" - "spotify" "adoptopenjdk-hotspot-bin" - "osu-lazer-bin-2023.1229.0" - "protonup-qt-2.8.2" - "cef-binary" - #"virtualbox" - #"virtualbox-modules" - #"open-watcom-bin" - #"open-watcom-bin-unwrapped" - "sof-firmware" "cargo-bootstrap" - "rustc-bootstrap-wrapper" + "cef-binary" "rustc-bootstrap" + "rustc-bootstrap-wrapper" + "sof-firmware" + "spotify" + "vscodium" ]; allowUnfree = false; allowUnfreePredicate = pkg: builtins.elem (lib.getName pkg) [ "nvidia-x11" - #"nvidia-settings" - #"nvidia-persistenced" - "xow_dongle-firmware" - #"facetimehd-firmware" - "osu-lazer-bin-2023.1229.0" "spotify" "steam" "steam-original" - "steam-run" + "xow_dongle-firmware" ]; }; } diff --git a/hosts/Aristotle/default.nix b/hosts/Aristotle/default.nix index de6894c..699a42f 100644 --- a/hosts/Aristotle/default.nix +++ b/hosts/Aristotle/default.nix @@ -9,6 +9,7 @@ # Hardware ./hardware-configuration.nix + ./anti-feature.nix ../../nixos/profiles/common/opt-in/lanzaboote.nix ../../nixos/profiles/common/opt-in/impermanence.nix ../../nixos/profiles/common/opt-in/disko.nix diff --git a/nixos/profiles/common/core/default.nix b/nixos/profiles/common/core/default.nix index 4f2ad07..17f8225 100644 --- a/nixos/profiles/common/core/default.nix +++ b/nixos/profiles/common/core/default.nix @@ -9,7 +9,6 @@ ./hardening ./networking ./nix - ./anti-feature.nix # Flake modules inputs.self.nixosModules.default