adds docker to dnsc-vps-sm

This commit is contained in:
Dennis 2025-07-07 09:09:28 +02:00
parent 1736bb1e6d
commit c93db5a8f0
3 changed files with 34 additions and 11 deletions

View file

@ -4,3 +4,4 @@
- [ ] Creation of SSH Keys
- [ ] Restic root SSH config & keys (even better: do not run restic as root)
- [ ] Splitpro

View file

@ -5,7 +5,8 @@
config,
pkgs,
...
}: {
}:
{
imports = [
./hardware-configuration.nix
./networking.nix
@ -14,6 +15,7 @@
../../modules/vaultwarden
../../modules/uptime-kuma
../../modules/homepage
../../modules/docker
];
# Secrets
@ -84,7 +86,10 @@
description = "dennis";
initialPassword = "admin";
isNormalUser = true;
extraGroups = [ "wheel" "networkmanager" ];
extraGroups = [
"wheel"
"networkmanager"
];
openssh.authorizedKeys.keys = [
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAILvXWZOPOJJDAoF+Sx/ZLoAVu6G/7/MAWoknBgMAzjul dennis@dnsc-mac"
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIKnmuxDkpDIku5t1Tykz21u78xoQ7LJR8JEcfth32LGu dennis@dnsc-work"
@ -101,7 +106,10 @@
};
# Enable new Nix CLI and flakes
nix.settings.experimental-features = [ "nix-command" "flakes" ];
nix.settings.experimental-features = [
"nix-command"
"flakes"
];
# Install system wide packages
environment.systemPackages = with pkgs; [
@ -109,6 +117,7 @@
btop
neovim
wget
docker-compose
];
# Programs
@ -160,6 +169,9 @@
virtualHosts."home.dnsc.io".extraConfig = ''
reverse_proxy localhost:9001
'';
virtualHosts."split.dnsc.io".extraConfig = ''
reverse_proxy localhost:9002
'';
};
# Environment variables
@ -175,4 +187,3 @@
# For more information, see `man configuration.nix` or https://nixos.org/manual/nixos/stable/options#opt-system.stateVersion .
system.stateVersion = "23.11";
}

View file

@ -0,0 +1,11 @@
{
virtualization.docker = {
enable = true;
rootless = {
enable = true;
setSocketVariable = true;
};
};
users.users.dennis.extraGroups = [ "docker" ];
}