add logical overview

This commit is contained in:
XenGi 2025-09-16 15:18:27 +02:00
parent 31430b4250
commit af760745d0
Signed by: xengi
SSH key fingerprint: SHA256:jxWM2RTHvxxcncXycwwWkP7HCWb4VREN05UGJTbIPZg
4 changed files with 256 additions and 63 deletions

View file

@ -1,3 +1,24 @@
# iac
Nix IaC
![k8s](k8s.svg)
## Hardware
Dell PowerEdge R630
- 2x Intel Xeon E5-2699C v4 (22C44T@2.2GHz)
- 24x 16GB DDR4 ECC 1866MHz (384GB)
## Virtual machines
### master-01 - master-03
- CPU: 2
- RAM: 8GB
### worker-01 - worker-05
- CPU: 16
- RAM: 64GB

160
flake.lock generated Normal file
View file

@ -0,0 +1,160 @@
{
"nodes": {
"agenix": {
"inputs": {
"darwin": "darwin",
"home-manager": "home-manager",
"nixpkgs": [
"nixpkgs"
],
"systems": "systems"
},
"locked": {
"lastModified": 1754433428,
"narHash": "sha256-NA/FT2hVhKDftbHSwVnoRTFhes62+7dxZbxj5Gxvghs=",
"owner": "ryantm",
"repo": "agenix",
"rev": "9edb1787864c4f59ae5074ad498b6272b3ec308d",
"type": "github"
},
"original": {
"owner": "ryantm",
"repo": "agenix",
"type": "github"
}
},
"darwin": {
"inputs": {
"nixpkgs": [
"agenix",
"nixpkgs"
]
},
"locked": {
"lastModified": 1744478979,
"narHash": "sha256-dyN+teG9G82G+m+PX/aSAagkC+vUv0SgUw3XkPhQodQ=",
"owner": "lnl7",
"repo": "nix-darwin",
"rev": "43975d782b418ebf4969e9ccba82466728c2851b",
"type": "github"
},
"original": {
"owner": "lnl7",
"ref": "master",
"repo": "nix-darwin",
"type": "github"
}
},
"flake-utils": {
"inputs": {
"systems": "systems_2"
},
"locked": {
"lastModified": 1731533236,
"narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "11707dc2f618dd54ca8739b309ec4fc024de578b",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"home-manager": {
"inputs": {
"nixpkgs": [
"agenix",
"nixpkgs"
]
},
"locked": {
"lastModified": 1745494811,
"narHash": "sha256-YZCh2o9Ua1n9uCvrvi5pRxtuVNml8X2a03qIFfRKpFs=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "abfad3d2958c9e6300a883bd443512c55dfeb1be",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "home-manager",
"type": "github"
}
},
"nixpkgs": {
"locked": {
"lastModified": 1757810152,
"narHash": "sha256-Vp9K5ol6h0J90jG7Rm4RWZsCB3x7v5VPx588TQ1dkfs=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "9a094440e02a699be5c57453a092a8baf569bdad",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixos-25.05",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs-k8s": {
"locked": {
"lastModified": 1755247647,
"narHash": "sha256-7Yu6USLkeTh2nirvXCdBFrAWc1yGYDdFv2tvXKU14Po=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "4acc7f1d238d2b4f5d86bc65ca9b703d802e6e02",
"type": "github"
},
"original": {
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "4acc7f1d238d2b4f5d86bc65ca9b703d802e6e02",
"type": "github"
}
},
"root": {
"inputs": {
"agenix": "agenix",
"flake-utils": "flake-utils",
"nixpkgs": "nixpkgs",
"nixpkgs-k8s": "nixpkgs-k8s"
}
},
"systems": {
"locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default",
"type": "github"
}
},
"systems_2": {
"locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default",
"type": "github"
}
}
},
"root": "root",
"version": 7
}

View file

@ -1,21 +1,30 @@
{
description = "flake to deploy and manage cccb k8s cluster"
description = "flake to deploy and manage cccb k8s cluster";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-25.05"
nixpkgs-k8s.url = "github:NixOS/nixpkgs/846711e6d39699c930ea30630f57bbdc1b7bf824" # kubernetes 1.33.1
nixpkgs.url = "github:NixOS/nixpkgs/nixos-25.05";
nixpkgs-k8s.url = "github:NixOS/nixpkgs/4acc7f1d238d2b4f5d86bc65ca9b703d802e6e02"; # kubernetes 1.33.4
flake-utils.url = "github:numtide/flake-utils";
agenix = {
url = "github:ryantm/agenix";
inputs.nixpkgs.follows = "nixpkgs";
};
};
outputs = { self, nixpkgs, nixpkgs-k8s, flake-utils, agenix }: flake-utils.lib.eachDefaultSystem (system:
outputs =
{
self,
nixpkgs,
nixpkgs-k8s,
flake-utils,
agenix,
}:
flake-utils.lib.eachDefaultSystem (
system:
let
pkgs = import nixpkgs { inherit system };
pkgs-k8s = import nixpkgs-k8s { inherit system };
pkgs = import nixpkgs { inherit system; };
pkgs-k8s = import nixpkgs-k8s { inherit system; };
in
{
formatter = pkgs.nixpkgs-fmt;
formatter = pkgs.nixfmt-tree;
devShells.default = pkgs.mkShell {
packages = with pkgs; [
agenix.packages.${system}.default
@ -30,8 +39,9 @@
openssl
];
};
# Dell R630
nixosConfigurations."k8s" = nixpkgs.lib.nixosSystem {
inherit system;
system = "x86_64-linux";
modules = [
agenix.nixosModules.default
{ environment.systemPackages = [ agenix.packages.${system}.default ]; }
@ -68,5 +78,6 @@
#./services/k8s-scheduler.nix
];
};
});
}
);
}

1
k8s.svg Normal file

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 16 KiB