Nix configurations for my homelab
1{ config, lib, ... }:
2{
3 options.garden.unfree = lib.mkOption {
4 type = with lib.types; listOf str;
5 default = [ ];
6 description = "A list of unfree packages that are allowed to be installed";
7 };
8
9 config.nixpkgs.config.allowUnfreePredicate = pkg: builtins.elem (lib.getName pkg) config.garden.unfree;
10}