Mount /nix into Kubernetes pods using the CSI Ephemeral Volume feature. Volumes share lifetime with Pods and are embedded into the Podspec.
Stick your pubkeys in ./keys and they will be imported into the module system then run the following command and you'll have nix-csi deployed.
nix run --file . kubenixEval.deploymentScript -- --yes --pruneIf you'd rather mangle YAML yourself you can use
nix build --file . easykubenix.manifestYAMLFileand stuff the result into Kustomize, a blender or your Kubernetes cluster
- multi-system example
- single-system ci example(s)
- YAML example, because YAML is....cool
volumeAttributes:
# Pull storePath without eval, prio 1
x86_64-linux: /nix/store/hello-......
aarch64-linux: /nix/store/hello-......
# Evaluates and builds flake, prio 2
flakeRef: github:nixos/nixpkgs/nixos-unstable#hello
# Evaluates and builds expression, prio 3
nixExpr: |
let
nixpkgs = builtins.fetchTree {
type = "github";
owner = "nixos";
repo = "nixpkgs";
ref = "nixos-unstable";
};
pkgs = import nixpkgs { };
in
pkgs.helloYou can specify all these options but the first successful one by priority wins