1a737bd471
Note: not the actual initial commit. I swear I will stop repeatedly force pushing to this single commit eventually ok.
90 lines
1.7 KiB
Nix
90 lines
1.7 KiB
Nix
{ pkgs, config, ... }:
|
|
|
|
{
|
|
imports = [
|
|
./services
|
|
./hardware-configuration.nix
|
|
];
|
|
|
|
time.timeZone = "America/Los_Angeles";
|
|
|
|
my = {
|
|
user = {
|
|
username = "serverie";
|
|
homeModule = ./home;
|
|
};
|
|
|
|
fs.bootPartition = false;
|
|
|
|
zram.writebackDevice = "/dev/sdb";
|
|
|
|
cli.fish.enable = true;
|
|
};
|
|
|
|
boot = {
|
|
initrd.availableKernelModules = [
|
|
"virtio_pci"
|
|
"virtio_scsi"
|
|
"ahci"
|
|
"sd_mod"
|
|
];
|
|
|
|
kernelParams = [ "console=ttyS0,19200n8" ];
|
|
kernelModules = [ "virtio_net" ];
|
|
|
|
loader = {
|
|
timeout = 10;
|
|
grub = {
|
|
enable = true;
|
|
forceInstall = true;
|
|
device = "nodev";
|
|
extraConfig = ''
|
|
serial --speed=19200 --unit=0 --word=8 --parity=no --stop=1;
|
|
terminal_input serial;
|
|
terminal_output serial
|
|
'';
|
|
};
|
|
};
|
|
};
|
|
|
|
networking = {
|
|
usePredictableInterfaceNames = false;
|
|
useDHCP = false;
|
|
interfaces.eth0 = {
|
|
useDHCP = true;
|
|
tempAddress = "disabled";
|
|
};
|
|
};
|
|
|
|
environment.systemPackages = with pkgs; [
|
|
inetutils
|
|
mtr
|
|
sysstat
|
|
|
|
nil
|
|
];
|
|
|
|
documentation.enable = false;
|
|
|
|
services = {
|
|
openssh = {
|
|
enable = true;
|
|
settings = {
|
|
LoginGraceTime = 0;
|
|
PasswordAuthentication = false;
|
|
PermitRootLogin = "no";
|
|
};
|
|
};
|
|
};
|
|
|
|
|
|
users.users.${config.my.user.username} = {
|
|
openssh.authorizedKeys.keys = [
|
|
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIElnlmCCIRhwe7z/a4dpwNoPF65II8NsOHUWJIBdr2Rg errie@nix-laptop"
|
|
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIFDWYERkHOqml1ntOUp8iZRTtvuAVUXcT4RRdqYtvxBy u0_a313@localhost"
|
|
];
|
|
};
|
|
|
|
system.stateVersion = "23.05";
|
|
}
|