dotnix/machines/dragonwell/default.nix

54 lines
1.4 KiB
Nix
Raw Normal View History

{pkgs, ...}: let
username = "jolheiser";
in {
imports = [./hardware.nix];
nixpkgs.config.allowUnfree = true;
nix = {
gc.automatic = true;
package = pkgs.nixVersions.nix_2_15;
settings = {
experimental-features = ["flakes" "nix-command" "repl-flake"];
auto-optimise-store = true;
warn-dirty = false;
};
};
system.activationScripts.diff = {
supportsDryActivation = true;
text = ''
${pkgs.nvd}/bin/nvd --nix-bin-dir=${pkgs.nix}/bin diff /run/current-system "$systemConfig"
'';
};
boot.tmp.cleanOnBoot = true;
zramSwap.enable = true;
networking = {
hostName = "dragonwell";
firewall.enable = true;
};
services = {
openssh = {
enable = true;
};
tailscale.enable = true;
};
virtualisation.docker.enable = true;
users.users."${username}" = {
extraGroups = ["wheel" "docker" "storage"];
isNormalUser = true;
openssh.authorizedKeys.keys = [
''ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDfKqCWtDlS3tgvfT6hQN+ii8UtabIZ+ZNmYN+bLwIa8PHOEW5MbfaqXSlhKkSi4+7SfQDCHphw0SMfhsQ4qMEcoywZ+4niDgKlQEVkl+S/VGbLuPe92NRStkyreZBLPr3Rh7ScNlGHcmHmoV9v7725fMnsMmabGVhpGO84PwNHOfJyv2tx2h6LxFbAV8S44UQu2lc8YLWCK2UvKuRnBerBXLnDQThUUX8UuCFzb786gQzD5XDU0MENbByxiy0XdVGAC+tFXEiSIgFZlFbFYyShgdTP9MzX2MOglEi+ae+1UIFncraW7ptUey7qHFJylpHWWWvE+GTwsg2G50i0FvFj jolheiser@jolheiser''
];
};
system.stateVersion = "22.11";
}