Skip to content

Commit

Permalink
γ€ŒπŸŽ‰γ€ init(quantum-moon): new host (server)
Browse files Browse the repository at this point in the history
  • Loading branch information
sh-koh committed Sep 21, 2024
1 parent 693a7ea commit f632e12
Show file tree
Hide file tree
Showing 7 changed files with 93 additions and 16 deletions.
22 changes: 6 additions & 16 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 10 additions & 0 deletions hosts/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,16 @@ in
./atrebois
./rocaille
./cravite
#./timber-hearth #atrebois
#./attlerock #rocaille
#./brittle-hollow #cravite
#./hollows-lantern #lanterne
#./giants-deep #leviathe
#./ash-twin #sablière rouge
#./ember-twin #sablière noire
#./dark-bramble #sombronce
./quantum-moon #lune quantique
#./interloper #l'intrus
];

_module.args = {
Expand Down
8 changes: 8 additions & 0 deletions hosts/quantum-moon/cfg.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{ inputs, ... }:
let
inherit (inputs.self.lib.sshKeys.shakoh.toQuantumMoon) atrebois rocaille;
in
{
networking.hostName = "quantum-moon";
users.users.shakoh.openssh.authorizedKeys.keys = [ atrebois rocaille ];
}
21 changes: 21 additions & 0 deletions hosts/quantum-moon/default.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
config,
mkNixos,
withSystem,
...
}:
let
inherit (config.flake) nixosModules;
in
{
flake.nixosConfigurations.quantum-moon = withSystem "aarch64-linux" ({ ... }:
mkNixos "aarch64-linux" [
./cfg.nix
./hw.nix

nixosModules.docker
nixosModules.nix
nixosModules.vfio
]
);
}
5 changes: 5 additions & 0 deletions hosts/quantum-moon/home.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{ pkgs, ... }:
{
home.packages = with pkgs; [
];
}
39 changes: 39 additions & 0 deletions hosts/quantum-moon/hw.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
{
config,
lib,
modulesPath,
...
}:
{
imports = [
(modulesPath + "/profiles/qemu-guest.nix")
];

boot = {
initrd = {
availableKernelModules = [ "xhci_pci" "virtio_scsi" "sr_mod" ];
};
};

fileSystems = {
"/" = {
device = "/dev/disk/by-label/ROOT";
fsType = "ext4";
};

"/nix" = {
device = "/dev/disk/by-label/NIX";
fsType = "ext4";
};

"/boot" = {
device = "/dev/disk/by-label/BOOT";
fsType = "vfat";
options = [ "fmask=0022" "dmask=0022" ];
};
};

nixpkgs.hostPlatform = lib.mkDefault "aarch64-linux";
nixpkgs.config.allowUnfree = true;
system.stateVersion = "24.05";
}
4 changes: 4 additions & 0 deletions lib/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,10 @@
atrebois = "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQCgByiZNkEDYHzVbOlaKJSweJ2uPjuRacQDfTXO5Dwcaq0rRQXjzkarC3YpBo8mqeam09CnSQBM5XFXlt4GFr8fScw0MSfcPEvj16ybgI/b2opg8a3OPGQ29rz9setUBmKYPRD94K7khwqu/tp39+2tvEI8J4HeBGXV1tmyCjrdFWXfbPdJwmi32cAlwAEcUDHrlXUXU4Kk0kbnN13VUx+rL6o/+MCeAb2NDJuo8mfMzWM2Z/DiKvz4qFnUDW43gDC4YqNMIAFuaFcCudvpJwYlTkHz46V6ErQ16ZB7S++qgL+0wn/pER7vvmtH7E4sPjN1gZsKskZoOy3WdcXXGXxpu46AmbLBvGnnp6V3x/n5/OZAtP0AgD4yM6gZnNF5G5kUoEu0b1txqYUhLBLvoLyOZtVjMUE5kq3o2rlnLYSapKO36Zfexm8q1IYs6APC5bTlt8Eo7rSaFwA8LrMrQbdXFbIrvm67fVoPeQgdS2DJ4QVX98exf/kVeoZszMeg2/irpSodSvqcfdlnALtzvxIXZO9lYgfQOyZelmHuh5HzrzUWUlI2goMbyJ+JYf8BH+DVVSXS1UwQysBi5lRGETsX0q/8wsjDrkKsPERd9ue7E7fkdoUCMUbA29G0aswEuR4dh7C+qOktJ4z2mVr2ew8CEGesIARnW7RZvJNg53pX9Q== shakoh@atrebois";
rocaille = "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQDcsKJPBMqyHS2TmYBFFyP+jGGFnOXnNY7/JWUwD1mWS3p6gMxtXTHZAAXLq/g2SG3gHUSpCWcytC9x5IFmYpf/9BCVZHwuUf8gSSQSAycTDoGWeY0AQ1KEOIUAQ1wWlG3iLFlaI48ugBR3m+gv2YlpY9FU47uj3bgIn6KF1fZCPFetQtIPE1TaKOYgd6M27deOo2pNxGQiGkvAkogfb7tqRjQQ5aWmtk4Uc32N8Frhce5QUWuI8AOqf4MfPXVOq6EyK0TLYPE+WEBSbf6kumme+BCwZ2SFN++yFJzVqGJQReRJJFXEf5vSRXN/60Rue0eF/GCbR838TiF+nDjge7W9jhABvUc0wNwlwHtSYoOVqxNuhwukaEcYhCnoiaerbwulPg4DJnD9eaBuH39b9+pEDp9b2AIB6jUaAU+zQ6GyGDVbJrcf+jVAMEn2ZqXRfLyRjNiof+0mivMgJ/vR1MxtcBD0NRV3n49CkvQNG4jrB6M738OzsudP0nkkwfyVHI4ZcAgwOqvY2KUEDnLyHvVOnr45zKvbbiKwfkAFRQevFgjClUJYJutfyo8bfZNxOyrVp0hCstgJ2lBqzAP2G65sO/VkLCqVLU/rV5ZoXt2sRCEnq5m2WtflL3nMcwDSUyl+HLqsd/T1AooOFJHLOd9bBaLOrsucogrj/Y+UkKIlYw== shakoh@rocaille"; # TODO
};
toQuantumMoon = {
atrebois = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIHZ6GyneISWLjtv8nRnV9T2wq/Vmjpt5ulOROEMDYgrt";
rocaille = "";
};
};
};
};
Expand Down

0 comments on commit f632e12

Please sign in to comment.