aboutsummaryrefslogtreecommitdiffstats
path: root/modules/nixos
diff options
context:
space:
mode:
Diffstat (limited to 'modules/nixos')
-rw-r--r--modules/nixos/common.nix16
1 files changed, 10 insertions, 6 deletions
diff --git a/modules/nixos/common.nix b/modules/nixos/common.nix
index 10f48c6..9ee164b 100644
--- a/modules/nixos/common.nix
+++ b/modules/nixos/common.nix
@@ -18,7 +18,10 @@
18 18
19 users.users.tom = { 19 users.users.tom = {
20 isNormalUser = true; 20 isNormalUser = true;
21 extraGroups = [ "wheel" ]; 21 extraGroups = [
22 "wheel"
23 "docker"
24 ];
22 shell = pkgs.bash; 25 shell = pkgs.bash;
23 # Fetched once from https://github.com/tomvanderlee.keys and pinned here 26 # Fetched once from https://github.com/tomvanderlee.keys and pinned here
24 # as a static literal (not fetched at build time, which would require 27 # as a static literal (not fetched at build time, which would require
@@ -69,9 +72,10 @@
69 openFirewall = true; 72 openFirewall = true;
70 }; 73 };
71 74
72 # Rootless: runs as the user's own systemd user service, not as root, and 75 # Rootful: standard system service, starts at boot independent of any
73 # has no docker-group privilege-escalation path. setSocketVariable exports 76 # login session (rootless was tried first but its per-user systemd unit
74 # DOCKER_HOST automatically so the docker CLI (dev-tools.nix) just works. 77 # didn't reliably start in already-logged-in sessions after a switch).
75 virtualisation.docker.rootless.enable = true; 78 # tom's docker group membership is root-equivalent access, accepted here
76 virtualisation.docker.rootless.setSocketVariable = true; 79 # for reliability over the rootless isolation guarantee.
80 virtualisation.docker.enable = true;
77} 81}