Change structure, add scanner deps and fix configurations

This commit is contained in:
2026-04-10 23:26:05 +02:00
parent d94d17b139
commit 1df132a22d
16 changed files with 68 additions and 110 deletions
-15
View File
@@ -1,15 +0,0 @@
{ lib, config, ... }:
with lib;
let
cfg = config.os.networks.manager;
in
{
options.os.networks.manager = {
enable = mkEnableOption "System networks manager service";
};
config = mkIf cfg.enable {
networking.networkmanager.enable = true;
};
}
@@ -1,11 +1,11 @@
{ lib, config, ... }:
with lib;
let
cfg = config.os.networks.dns;
cfg = config.os.networking;
in
{
options.os.networks.dns = {
enable = mkEnableOption "System dns service";
options.os.networking = {
enable = mkEnableOption "System networks manager service";
};
config = mkIf cfg.enable {
@@ -17,5 +17,7 @@ in
openFirewall = true;
};
networking.networkmanager.enable = true;
};
}
@@ -1,4 +1,5 @@
{
pkgs,
lib,
config,
...
@@ -6,6 +7,8 @@
with lib;
let
cfg = config.os.networks.printing;
all = builtins.attrNames config.users.users;
users = builtins.filter (user: config.users.users.${user}.isNormalUser == true) all;
in
{
options.os.networks.printing = {
@@ -15,7 +18,17 @@ in
services.printing = {
enable = true;
startWhenNeeded = true;
drivers = with pkgs; [ hplip ];
};
hardware.sane = {
enable = true;
extraBackends = with pkgs; [ sane-airscan ];
};
users.groups.lp.members = users;
users.groups.scanner.members = users;
};
}