add host Remilia

This commit is contained in:
2021-05-31 02:48:14 +05:30
parent 8952fafe65
commit 02fa695a0f
25 changed files with 98 additions and 32 deletions

13
hosts/servers/remilia/boot.nix Executable file
View File

@@ -0,0 +1,13 @@
{config, ...}:
{
boot = {
initrd.kernelModules = [ "bochs_drm" ];
initrd.availableKernelModules = [ "ata_piix" "uhci_hcd" "virtio_pci" "virtio_scsi" ];
kernelModules = [ "kvm-amd" ];
kernelParams = [ "console=ttyS0" "console=tty1" "nvme.shutdown_timeout=10" "libiscsi.debug_libiscsi_eh=1" ];
loader = {
systemd-boot.enable = true;
efi.canTouchEfiVariables = true;
};
};
}

View File

@@ -0,0 +1,20 @@
{ config, lib, pkgs, modulesPath, ... }:
{
imports =
[ (modulesPath + "/profiles/qemu-guest.nix")
];
fileSystems."/" =
{ device = "/dev/disk/by-uuid/d91adce2-9059-4a8a-86e7-dee6ecc85b2b";
fsType = "ext4";
};
swapDevices = [
{
device="/swapfile";
size = 7168;
priority = 0;
}
];
}

View File

@@ -0,0 +1,13 @@
{config, ...}:
{
networking = {
useDHCP = false;
hostName = "Remilia";
firewall.allowedTCPPorts = [ 22 80 ];
interfaces = {
ens3 = {
useDHCP = true;
};
};
};
}

View File

@@ -0,0 +1,12 @@
{config, ...}:
{
services = {
openssh = {
enable = true;
permitRootLogin = "yes";
};
};
users.users.root.openssh.authorizedKeys.keys = [
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJHingN2Aho+KGgEvBMjtoez+W1svl9uVoa4vG0d646j"
];
}