refactor(packages): split core packages from per-host extras
modules/system/packages.nix now exposes myPackages.extra so hosts can add their own tools on top of the always-installed core set, instead of hardcoding every host's packages in one shared list. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
1 parent
933afc7d11
commit
7c2a09a360
3 files changed
+31
-12
No files matched your search
@@ -12,6 +12,13 @@
|
|||||||
|
|
||||||
age.secrets.miku-homelab-wg.file = ../../secrets/miku-homelab-wg.age;
|
age.secrets.miku-homelab-wg.file = ../../secrets/miku-homelab-wg.age;
|
||||||
|
|
||||||
|
myPackages.extra = with pkgs; [
|
||||||
|
rocmPackages.rocm-smi
|
||||||
|
btrfs-progs
|
||||||
|
distrobox
|
||||||
|
steam-run
|
||||||
|
];
|
||||||
|
|
||||||
myNetworking = {
|
myNetworking = {
|
||||||
hostName = "miku-homelab";
|
hostName = "miku-homelab";
|
||||||
useNetworkManager = true;
|
useNetworkManager = true;
|
||||||
|
|||||||
@@ -4,6 +4,7 @@
|
|||||||
imports = [
|
imports = [
|
||||||
./hardware-configuration.nix
|
./hardware-configuration.nix
|
||||||
../../modules/profiles/server.nix
|
../../modules/profiles/server.nix
|
||||||
|
../../modules/system/packages.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
# PLACEHOLDER: secrets/vps-wg.age does not exist yet. It has to be created
|
# PLACEHOLDER: secrets/vps-wg.age does not exist yet. It has to be created
|
||||||
|
|||||||
+23
-12
@@ -1,14 +1,25 @@
|
|||||||
{pkgs, ... }:
|
{ lib, pkgs, config, ... }:
|
||||||
|
|
||||||
|
let
|
||||||
|
cfg = config.myPackages;
|
||||||
|
in
|
||||||
{
|
{
|
||||||
environment.systemPackages = with pkgs; [
|
options.myPackages = {
|
||||||
git
|
extra = lib.mkOption {
|
||||||
wget
|
type = lib.types.listOf lib.types.package;
|
||||||
curl
|
default = [ ];
|
||||||
ethtool
|
description = "Extra packages to install on this host, beyond the core set.";
|
||||||
fish
|
};
|
||||||
rocmPackages.rocm-smi
|
};
|
||||||
btrfs-progs
|
|
||||||
distrobox
|
config = {
|
||||||
steam-run
|
environment.systemPackages = with pkgs; [
|
||||||
];
|
git
|
||||||
|
wget
|
||||||
|
curl
|
||||||
|
ethtool
|
||||||
|
fish
|
||||||
|
tmux
|
||||||
|
] ++ cfg.extra;
|
||||||
|
};
|
||||||
}
|
}
|
||||||
Reference in new issue
Block a user