nix: lazy way to add groups

This commit is contained in:
js0ny 2025-10-29 02:21:42 +00:00
parent 2b3fb09642
commit c58013738a
9 changed files with 17 additions and 79 deletions

View file

@ -30,9 +30,6 @@
isNormalUser = true;
extraGroups = [
"wheel"
"docker"
"libvirtd"
"dialout"
]; # Enable sudo for the user.
openssh.authorizedKeys.keys = [
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJToUo2jT3qt7eHIME9e1awabZZVmtKhbxwVz9BMSM2d js0ny@zephyrus"

View file

@ -5,5 +5,4 @@
korganizer
kdepim-addons
];
services.xserver.desktopManager.cinnamon.enable = true;
}

View file

@ -1,6 +1,9 @@
{...}: {
{config, ...}: {
# Xilinx Artix-7 Basys 3
services.udev.extraRules = ''
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="6010", MODE="0660", GROUP="dialout", SYMLINK+="basys3"
'';
users.users.${config.var.username} = {
extraGroups = ["dialout"];
};
}

View file

@ -1,4 +1,8 @@
{pkgs, ...}: {
{
pkgs,
config,
...
}: {
environment.systemPackages = with pkgs; [
virt-manager
dnsmasq
@ -13,7 +17,7 @@
swtpm.enable = true;
};
};
users.users.js0ny = {
users.users.${config.var.username} = {
extraGroups = ["libvirtd"];
};
networking.firewall.trustedInterfaces = ["virbr0"];

View file

@ -1,8 +1,11 @@
{pkgs, ...}: {
{config, ...}: {
virtualisation = {
docker.enable = true;
podman.enable = true;
};
users.users.${config.var.username} = {
extraGroups = ["docker" "podman"];
};
# systemd.services.docker = {
# serviceConfig = {