blob: 60848daa8091416cc849372f9f0af36db66b1bb9 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
|
{ pkgs, unfreeAndNonDistributablePkgs, config, lib, ... }:
let
inherit (lib) mkIf mkEnableOption mkOption;
cfg = config.vuizvui.user.aszlig.profiles.managed;
inherit (cfg) mainUser;
in {
options.vuizvui.user.aszlig.profiles.managed = {
enable = mkEnableOption "common profile for aszlig's managed machines";
mainUser = mkOption {
example = "foobar";
description = ''
Main user account of the managed system.
'';
};
};
config = mkIf cfg.enable {
environment.systemPackages = [ pkgs.simple-scan ];
# Printing for the most common printers among the managed machines.
services.printing.enable = true;
services.printing.drivers = [
pkgs.gutenprint
unfreeAndNonDistributablePkgs.hplipWithPlugin
];
# And also most common scanners are also HP ones.
hardware.sane.enable = true;
hardware.sane.extraBackends = [
unfreeAndNonDistributablePkgs.hplipWithPlugin
];
users.users.${mainUser} = {
isNormalUser = true;
uid = 1000;
extraGroups = [ "networkmanager" "scanner" "video" "wheel" ];
};
};
}
|