[cornu-aspersum] Add initial config

New machine hosted via Netcup, the RS2000 G9
This commit is contained in:
Malte Tammena 2021-12-18 12:41:35 +01:00
parent b71eceb97c
commit d234097569
3 changed files with 79 additions and 0 deletions

View file

@ -75,6 +75,14 @@
}; };
}; };
cornu-aspersum = { ... }: {
imports = [ self.nixosModules.cornu-aspersum ];
config.deployment = {
targetHost = "ccqcraft.de";
targetUser = "root";
};
};
elysia-clarki = { ... }: { elysia-clarki = { ... }: {
imports = [ self.nixosModules.elysia-clarki ]; imports = [ self.nixosModules.elysia-clarki ];
config.deployment = { config.deployment = {
@ -140,6 +148,18 @@
]; ];
}; };
cornu-aspersum = { pkgs, ... }: {
imports = [
self.nixosModules.x86_64-linux-basics
#inputs.glados.nixosModules.glados
./hosts/cornu-aspersum.nix
./hardware/netcup-rs-2000-g9.nix
./modules/nginx-reverse-proxy.nix
#./modules/radicale.nix
#./modules/grafana.nix
];
};
elysia-clarki = { pkgs, ... }: { elysia-clarki = { pkgs, ... }: {
imports = [ imports = [
self.nixosModules.x86_64-linux-basics self.nixosModules.x86_64-linux-basics
@ -262,6 +282,12 @@
modules = [ self.nixosModules.achatina-fulica ]; modules = [ self.nixosModules.achatina-fulica ];
}; };
# Currently hosted by NetCup (mostly Minecraft server)
nixosConfigurations.cornu-aspersum = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
modules = [ self.nixosModules.cornu-aspersum ];
};
# Server @home # Server @home
nixosConfigurations.elysia-clarki = nixpkgs.lib.nixosSystem { nixosConfigurations.elysia-clarki = nixpkgs.lib.nixosSystem {
system = "x86_64-linux"; system = "x86_64-linux";

View file

@ -0,0 +1,19 @@
{ config, lib, pkgs, modulesPath, ... }:
{
imports = [ (modulesPath + "/profiles/qemu-guest.nix") ];
boot.initrd.availableKernelModules =
[ "ata_piix" "uhci_hcd" "virtio_pci" "virtio_scsi" "sd_mod" "sr_mod" ];
fileSystems."/" = {
device = "/dev/disk/by-uuid/c185b0bf-145d-4ec3-8848-73da24e5caf6";
fsType = "ext4";
};
swapDevices =
[{ device = "/dev/disk/by-uuid/112f05bd09ee0-4dfb-b94c-9c950ce411ff"; }];
hardware.cpu.amd.updateMicrocode =
lib.mkDefault config.hardware.enableRedistributableFirmware;
}

34
hosts/cornu-aspersum.nix Normal file
View file

@ -0,0 +1,34 @@
{ config, pkgs, ... }:
{
boot.loader.grub.enable = true;
boot.loader.grub.version = 2;
boot.loader.grub.device = "/dev/sda";
networking.hostId = "94d2a920";
networking.hostName = "cornu-aspersum";
networking.interfaces.ens3.useDHCP = true;
users.users = {
root = {
hashedPassword =
"$6$Yb1gdlKIpY1hRW1X$uUcNFuNnK2JFFN55Tkc.fPV.4I7RJvIfLEQayVP1utfkmjF0f/EHjtypxq11jR5NUUIJFQLW6ffajjduA2689.";
};
};
services.qemuGuest.enable = true;
# sops.defaultSopsFile = ../secrets/achatina-fulica/secrets.yaml;
# sops.age.sshKeyPaths = [ "/etc/ssh/ssh_host_ed25519_key" ];
# # This is the actual specification of the secrets.
# This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions
# on your system were taken. Its perfectly fine and recommended to leave
# this value at the release version of the first install of this system.
# Before changing this value read the documentation for this option
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
system.stateVersion = "21.05"; # Did you read the comment?
}