Files
infra-nix/modules/common.nix
T
danlin c4938a6c05 Remove plaintext secrets, update SSH key, and upgrade to NixOS 25.11
Replace initialPassword with hashedPassword for danlin user, move
FileBrowser admin password to external environmentFile with restricted
secrets directory, update SSH authorized key, and bump nixpkgs to 25.11.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-19 17:44:03 +01:00

53 lines
1.3 KiB
Nix

{ config, pkgs, ... }:
{
# Boot configuration
boot.loader.systemd-boot.enable = true;
boot.loader.efi.canTouchEfiVariables = true;
# Timezone
time.timeZone = "Europe/Berlin";
i18n.defaultLocale = "en_US.UTF-8";
# Security & sudo
security.sudo.enable = true;
security.sudo.wheelNeedsPassword = false;
# SSH configuration
services.openssh = {
enable = true;
settings = {
PermitRootLogin = "no";
PasswordAuthentication = false;
};
};
# User configuration
users.users.danlin = {
isNormalUser = true;
extraGroups = [ "wheel" ];
hashedPassword = "$6$tvQ8UVAZIOm4g8PI$u1HBwK1xVINiNFOm.MtbvGsXb8R5SvBHqdJpTLcvDHJcdWa4GcB/R3txARlu.s/bLhtnwoKSKUksQ5ETwyQ5u.";
openssh.authorizedKeys.keys = [
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIB+xf0lrobmWxml003CyjzEEZqUf2qbEv6vEGMGNUBAX danlin@MacBook-Pro-von-Daniel.fritz.box"
];
};
# Base system packages
environment.systemPackages = with pkgs; [
neovim
rclone
htop
curl
wget
apacheHttpd # Provides htpasswd for registry password management
];
# QEMU guest agent (for VM integration when running as guest)
services.qemuGuest.enable = true;
# Automatic updates (security)
system.autoUpgrade = {
enable = false; # Manual control via flake
allowReboot = false;
};
}