nix-deploy/config/hosts/nixos-testbed/configuration.nix

50 lines
1.1 KiB
Nix
Raw Normal View History

2021-09-27 14:55:55 +02:00
{ config, pkgs, lib, ... }:
{
imports = [
./hardware-configuration.nix
../../common/services/ssh.nix
];
boot.loader.grub.enable = true;
boot.loader.grub.version = 2;
boot.loader.grub.device = "/dev/sda";
networking.hostName = "nixos-testbed";
time.timeZone = "Europe/Copenhagen";
networking.useDHCP = false;
networking.interfaces.ens3.useDHCP = true;
networking.interfaces.ens3.ipv6.addresses = [ { address = "2a01:4f9:c011:50e2::1"; prefixLength = 64; } ];
networking.defaultGateway6 = { address = "fe80::1"; interface = "ens3"; };
users.users.emelie = {
isNormalUser = true;
extraGroups = [ "wheel" ];
openssh.authorizedKeys.keys = [
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAICO4LyBsW1YuUA6i3EL/IZhchSvk7reO4qgRmR/tdQPU emelie@flap"
];
};
security.sudo.wheelNeedsPassword = false;
environment.systemPackages = with pkgs; [
vim
htop
iotop
dig
];
nix = {
autoOptimiseStore = true;
trustedUsers = [
"root"
"@wheel"
];
};
# Use hetzner firewall instead
networking.firewall.enable = false;
system.stateVersion = "21.05";
}