Compare commits

...

2 commits

Author SHA1 Message Date
254433bc62
Revert "k3s: init"
This reverts commit 04a828d78d.
2025-08-30 18:13:27 +10:00
cded5bfdf7
users: add deploy 2025-08-30 18:13:07 +10:00
3 changed files with 29 additions and 13 deletions

View file

@ -34,7 +34,6 @@
./modules/applications/1password.nix
./modules/services/archiveteam-warrior.nix
./modules/services/linkding.nix
./modules/services/k3s.nix
./modules/nix/linux.nix
./modules/shell.nix
@ -52,6 +51,7 @@
./modules/users/nico.nix
./modules/users/alex.nix
./modules/users/deploy.nix
./modules/hardware/secureboot.nix
lanzaboote.nixosModules.lanzaboote

View file

@ -1,12 +0,0 @@
{ config, ... }:
{
services.k3s = {
enable = true;
role = "server";
};
networking.firewall.allowedTCPPorts = [
6443 # k3s: required so that pods can reach the API server (running on port 6443 by default)
];
}

28
modules/users/deploy.nix Normal file
View file

@ -0,0 +1,28 @@
{ config, lib, pkgs, ...}:
{
users.users.deploy = {
isNormalUser = true;
home = "/var/empty";
group = "deploy";
};
users.groups.deploy = {};
users.users.deploy.openssh.authorizedKeys.keys = [
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAILXwl+UyfeN/9M/z21mlVS3guYEqIjtgAf5pCPkjXhR0"
];
security.sudo.extraRules = [
{
users = [ "deploy" ];
runAs = "root";
commands = [
{
command = "ALL";
options = [ "NOPASSWD" ];
}
];
}
];
}