feat(servers): add baldur, the immortal
This commit is contained in:
parent
79420d9b7c
commit
8c4e9f6641
20
flake.nix
20
flake.nix
@ -105,6 +105,15 @@
|
||||
path = deploy-rs.lib.x86_64-linux.activate.nixos self.nixosConfigurations.loki;
|
||||
};
|
||||
};
|
||||
|
||||
baldur = {
|
||||
hostname = "baldur";
|
||||
profiles.system = {
|
||||
sshUser = "root";
|
||||
user = "root";
|
||||
path = deploy-rs.lib.aarch64-linux.activate.nixos self.nixosConfigurations.baldur;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
nixOnDroidConfigurations.default = nix-on-droid.lib.nixOnDroidConfiguration {
|
||||
@ -141,6 +150,17 @@
|
||||
];
|
||||
};
|
||||
|
||||
baldur = nixpkgs.lib.nixosSystem {
|
||||
system = "aarch64-linux";
|
||||
modules = [
|
||||
disko.nixosModules.disko
|
||||
agenix.nixosModules.default
|
||||
./hosts/baldur/configuration.nix
|
||||
./modules/servers/general
|
||||
./modules/servers/baldur
|
||||
];
|
||||
};
|
||||
|
||||
nixos = nixpkgs.lib.nixosSystem {
|
||||
specialArgs = {inherit inputs;};
|
||||
modules = [
|
||||
|
27
hosts/baldur/configuration.nix
Normal file
27
hosts/baldur/configuration.nix
Normal file
@ -0,0 +1,27 @@
|
||||
{
|
||||
modulesPath,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}: {
|
||||
imports = [
|
||||
(modulesPath + "/installer/scan/not-detected.nix")
|
||||
(modulesPath + "/profiles/qemu-guest.nix")
|
||||
./disk-config.nix
|
||||
];
|
||||
|
||||
networking.hostName = "baldur";
|
||||
|
||||
boot.loader.grub = {
|
||||
efiSupport = true;
|
||||
efiInstallAsRemovable = true;
|
||||
};
|
||||
|
||||
environment.systemPackages = map lib.lowPrio [
|
||||
pkgs.curl
|
||||
pkgs.neovim
|
||||
pkgs.gitMinimal
|
||||
];
|
||||
|
||||
system.stateVersion = "24.05";
|
||||
}
|
54
hosts/baldur/disk-config.nix
Normal file
54
hosts/baldur/disk-config.nix
Normal file
@ -0,0 +1,54 @@
|
||||
{lib, ...}: {
|
||||
disko.devices = {
|
||||
disk.disk1 = {
|
||||
device = lib.mkDefault "/dev/sda";
|
||||
type = "disk";
|
||||
content = {
|
||||
type = "gpt";
|
||||
partitions = {
|
||||
boot = {
|
||||
name = "boot";
|
||||
size = "1M";
|
||||
type = "EF02";
|
||||
};
|
||||
esp = {
|
||||
name = "ESP";
|
||||
size = "500M";
|
||||
type = "EF00";
|
||||
content = {
|
||||
type = "filesystem";
|
||||
format = "vfat";
|
||||
mountpoint = "/boot";
|
||||
};
|
||||
};
|
||||
root = {
|
||||
name = "root";
|
||||
size = "100%";
|
||||
content = {
|
||||
type = "lvm_pv";
|
||||
vg = "pool";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
lvm_vg = {
|
||||
pool = {
|
||||
type = "lvm_vg";
|
||||
lvs = {
|
||||
root = {
|
||||
size = "100%FREE";
|
||||
content = {
|
||||
type = "filesystem";
|
||||
format = "ext4";
|
||||
mountpoint = "/";
|
||||
mountOptions = [
|
||||
"defaults"
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
@ -25,6 +25,9 @@
|
||||
# Enable flakes
|
||||
nix.settings.experimental-features = ["nix-command" "flakes"];
|
||||
|
||||
# Enable trusted users
|
||||
nix.trustedUsers = ["root" "@wheel"];
|
||||
|
||||
# Setup gpu
|
||||
hardware.graphics = {
|
||||
enable = true;
|
||||
|
1
modules/servers/baldur/default.nix
Normal file
1
modules/servers/baldur/default.nix
Normal file
@ -0,0 +1 @@
|
||||
{...}: {}
|
@ -2,6 +2,7 @@ let
|
||||
# SYSTEMS
|
||||
heimdall = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIBs+qYjpeAEHPFUQeatNkhKbXz8+A1VAl21jgifDYJK8";
|
||||
loki = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIF+xpWCoBEO/pzAwS1ZZEsiLSarvSVkdxQEo49xma2PV";
|
||||
baldur = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIOvZ7Z8GS4+1+9D6u/BDit4Eij5Ubbii2dzJ/+ecT8iR";
|
||||
|
||||
# USERS
|
||||
root = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIBJLduAXHWJiglmfRfkBGKffzVWkJP6porxIzw6+Zz3W crony@cronyakatsuki.xyz";
|
||||
@ -9,7 +10,7 @@ let
|
||||
users = [
|
||||
root
|
||||
];
|
||||
systems = [heimdall loki];
|
||||
systems = [heimdall loki baldur];
|
||||
in {
|
||||
"traefik.age".publicKeys = systems ++ users;
|
||||
"wg-heimdall.age".publicKeys = systems ++ users;
|
||||
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user