feat: create router role

This commit is contained in:
Ahwx 2025-05-17 17:30:47 +02:00
parent 71d816fe80
commit 1b8b3f607d
2 changed files with 47 additions and 0 deletions

View file

@ -5,6 +5,7 @@
++ [ (import ./amdgpu.nix) ]
++ [ (import ./nvidia.nix) ]
++ [ (import ./server.nix) ]
++ [ (import ./router.nix) ]
++ [ (import ./desktop.nix) ]
++ [ (import ./wine.nix) ]
++ [ (import ./creative.nix) ]

46
roles/router.nix Normal file
View file

@ -0,0 +1,46 @@
{
lib,
pkgs,
config,
username,
home-manager,
...
}:
with lib;
let
cfg = config.liv.router;
in
{
options.liv.router = {
enable = mkEnableOption "Enable router";
};
config = mkIf cfg.enable {
environment.systemPackages = with pkgs; [
pkgs.kitty.terminfo
powertop
bind
];
services = {
thermald.enable = true;
vnstat.enable = true;
# cpupower-gui.enable = true;
# power-profiles-daemon.enable = true;
# auto-cpufreq = {
# enable = true;
# settings = {
# battery = {
# governor = "powersave";
# turbo = "auto";
# };
# charger = {
# governor = "performance";
# turbo = "auto";
# };
# };
# };
};
};
}