- Multi-host flake.nix (3x N97 x86_64 + 2x RPi4 aarch64) - Shared modules: k3s-cluster, tailscale, meos-gateway - Node configs: n97-1 (control plane), n97-2/n97-3 (Ollama workers), rpi4-1/rpi4-2 (ARM workers) - K8s manifests: Forgejo, Postgres (CNPG), Umami, OpenBrain, MeOS Dashboard, MCP servers - Bootstrap and DB migration scripts - Migration plan doc (7-day phased rollout)
48 lines
1.1 KiB
Nix
48 lines
1.1 KiB
Nix
{
|
|
description = "Scobleclaw Multi-Node Cluster — NixOS + k3s";
|
|
|
|
inputs = {
|
|
nixpkgs.url = "github:nixos/nixpkgs/nixos-25.11";
|
|
};
|
|
|
|
outputs = { self, nixpkgs }:
|
|
let
|
|
shared-modules = [
|
|
./modules/tailscale.nix
|
|
./modules/k3s-cluster.nix
|
|
];
|
|
|
|
mkSystem = system: hostModule: nixpkgs.lib.nixosSystem {
|
|
inherit system;
|
|
modules = shared-modules ++ [ hostModule ];
|
|
specialArgs = { inherit self; };
|
|
};
|
|
in {
|
|
nixosConfigurations = {
|
|
n97-1 = mkSystem "x86_64-linux" [
|
|
./hardware-n97.nix
|
|
./nodes/n97-1.nix
|
|
];
|
|
|
|
n97-2 = mkSystem "x86_64-linux" [
|
|
./hardware-n97.nix
|
|
./nodes/n97-2.nix
|
|
];
|
|
|
|
n97-3 = mkSystem "x86_64-linux" [
|
|
./hardware-n97.nix
|
|
./nodes/n97-3.nix
|
|
];
|
|
|
|
rpi4-1 = mkSystem "aarch64-linux" [
|
|
./hardware-rpi4.nix
|
|
./nodes/rpi4-1.nix
|
|
];
|
|
|
|
rpi4-2 = mkSystem "aarch64-linux" [
|
|
./hardware-rpi4.nix
|
|
./nodes/rpi4-2.nix
|
|
];
|
|
};
|
|
};
|
|
}
|