Compare commits
3 commits
53481414df
...
ba9e9f0916
Author | SHA1 | Date | |
---|---|---|---|
ba9e9f0916 | |||
e2c12867ec | |||
e4bc0b4ec4 |
4 changed files with 75 additions and 42 deletions
|
@ -157,7 +157,40 @@
|
||||||
|
|
||||||
../../snippets/holo-zerotier.nix
|
../../snippets/holo-zerotier.nix
|
||||||
|
|
||||||
../../snippets/k3s-w-nix-snapshotter.nix
|
# experiment with k3s, nix-snapshotter, and nixos images
|
||||||
|
{
|
||||||
|
# (1) Import nixos module.
|
||||||
|
imports = [
|
||||||
|
nodeFlake.inputs.nix-snapshotter.nixosModules.default
|
||||||
|
];
|
||||||
|
|
||||||
|
# (2) Add overlay.
|
||||||
|
nixpkgs.overlays = [nodeFlake.inputs.nix-snapshotter.overlays.default];
|
||||||
|
|
||||||
|
# (3) Enable service.
|
||||||
|
virtualisation.containerd = {
|
||||||
|
enable = true;
|
||||||
|
k3sIntegration = false;
|
||||||
|
nixSnapshotterIntegration = true;
|
||||||
|
|
||||||
|
# TODO: understand if this has an influence on the systemd LoadCredential issue
|
||||||
|
settings.plugins."io.containerd.grpc.v1.cri".containerd.runtimes.runc.options.SystemdCgroup = lib.mkForce true;
|
||||||
|
};
|
||||||
|
services.nix-snapshotter = {
|
||||||
|
enable = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
# (4) Add a containerd CLI like nerdctl.
|
||||||
|
environment.systemPackages = [
|
||||||
|
pkgs.nerdctl
|
||||||
|
nodeFlake.inputs.nix-snapshotter.packages.${system}.nix-snapshotter
|
||||||
|
];
|
||||||
|
|
||||||
|
services.k3s = {
|
||||||
|
enable = false;
|
||||||
|
setKubeConfig = true;
|
||||||
|
};
|
||||||
|
}
|
||||||
];
|
];
|
||||||
|
|
||||||
networking.hostName = nodeName;
|
networking.hostName = nodeName;
|
||||||
|
|
34
nix/os/devices/steveej-x13s/flake.lock
generated
34
nix/os/devices/steveej-x13s/flake.lock
generated
|
@ -1,5 +1,21 @@
|
||||||
{
|
{
|
||||||
"nodes": {
|
"nodes": {
|
||||||
|
"ath11k-firmware": {
|
||||||
|
"flake": false,
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1720482684,
|
||||||
|
"narHash": "sha256-p6ifwtRNUOyQ2FN2VhSXS6dcrvrtiFZawu/iVXQ4uR0=",
|
||||||
|
"ref": "refs/heads/main",
|
||||||
|
"rev": "bb527dcebac835c47ed4f5428a7687769fa9b1b2",
|
||||||
|
"revCount": 152,
|
||||||
|
"type": "git",
|
||||||
|
"url": "https://git.codelinaro.org/clo/ath-firmware/ath11k-firmware.git"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"type": "git",
|
||||||
|
"url": "https://git.codelinaro.org/clo/ath-firmware/ath11k-firmware.git"
|
||||||
|
}
|
||||||
|
},
|
||||||
"crane": {
|
"crane": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"nixpkgs": [
|
"nixpkgs": [
|
||||||
|
@ -162,6 +178,22 @@
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"mobile-nixos": {
|
||||||
|
"flake": false,
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1722056346,
|
||||||
|
"narHash": "sha256-50fcuCppaLMfSOTFO4IkCBs4folToCwlhTgc6IdZFHg=",
|
||||||
|
"owner": "NixOS",
|
||||||
|
"repo": "mobile-nixos",
|
||||||
|
"rev": "717ce90cfadffa449480bae2e155185c651e9993",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "NixOS",
|
||||||
|
"repo": "mobile-nixos",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
"mycelium": {
|
"mycelium": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"crane": "crane",
|
"crane": "crane",
|
||||||
|
@ -318,9 +350,11 @@
|
||||||
},
|
},
|
||||||
"root": {
|
"root": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
|
"ath11k-firmware": "ath11k-firmware",
|
||||||
"disko": "disko",
|
"disko": "disko",
|
||||||
"get-flake": "get-flake",
|
"get-flake": "get-flake",
|
||||||
"home-manager": "home-manager",
|
"home-manager": "home-manager",
|
||||||
|
"mobile-nixos": "mobile-nixos",
|
||||||
"mycelium": "mycelium",
|
"mycelium": "mycelium",
|
||||||
"nix-snapshotter": "nix-snapshotter",
|
"nix-snapshotter": "nix-snapshotter",
|
||||||
"nixos-x13s": "nixos-x13s",
|
"nixos-x13s": "nixos-x13s",
|
||||||
|
|
|
@ -26,12 +26,19 @@
|
||||||
# url = "github:pdtpartners/nix-snapshotter";
|
# url = "github:pdtpartners/nix-snapshotter";
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
nix-snapshotter = {
|
||||||
|
url = "github:yu-re-ka/nix-snapshotter";
|
||||||
|
# url = "github:pdtpartners/nix-snapshotter";
|
||||||
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs = {
|
outputs = {
|
||||||
self,
|
self,
|
||||||
get-flake,
|
get-flake,
|
||||||
nixpkgs,
|
nixpkgs,
|
||||||
|
ath11k-firmware,
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
targetPlatform = "aarch64-linux";
|
targetPlatform = "aarch64-linux";
|
||||||
|
|
|
@ -1,41 +0,0 @@
|
||||||
# experiment with k3s, nix-snapshotter, and nixos images
|
|
||||||
{
|
|
||||||
nodeFlake,
|
|
||||||
nodeFlakeInputs',
|
|
||||||
pkgs,
|
|
||||||
lib,
|
|
||||||
system,
|
|
||||||
...
|
|
||||||
}: {
|
|
||||||
# (1) Import nixos module.
|
|
||||||
imports = [
|
|
||||||
nodeFlake.inputs.nix-snapshotter.nixosModules.default
|
|
||||||
];
|
|
||||||
|
|
||||||
# (2) Add overlay.
|
|
||||||
nixpkgs.overlays = [nodeFlake.inputs.nix-snapshotter.overlays.default];
|
|
||||||
|
|
||||||
# (3) Enable service.
|
|
||||||
virtualisation.containerd = {
|
|
||||||
enable = true;
|
|
||||||
k3sIntegration = false;
|
|
||||||
nixSnapshotterIntegration = true;
|
|
||||||
|
|
||||||
# TODO: understand if this has an influence on the systemd LoadCredential issue
|
|
||||||
settings.plugins."io.containerd.grpc.v1.cri".containerd.runtimes.runc.options.SystemdCgroup = lib.mkForce true;
|
|
||||||
};
|
|
||||||
services.nix-snapshotter = {
|
|
||||||
enable = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
# (4) Add a containerd CLI like nerdctl.
|
|
||||||
environment.systemPackages = [
|
|
||||||
pkgs.nerdctl
|
|
||||||
nodeFlake.inputs.nix-snapshotter.packages.${system}.default
|
|
||||||
];
|
|
||||||
|
|
||||||
services.k3s = {
|
|
||||||
enable = false;
|
|
||||||
setKubeConfig = true;
|
|
||||||
};
|
|
||||||
}
|
|
Loading…
Add table
Add a link
Reference in a new issue