add new k8s version check

This commit is contained in:
Bryton Hall 2022-08-11 23:18:44 -04:00
parent 666a685118
commit 90de01f7d9
3 changed files with 5 additions and 2 deletions

View file

@ -19,6 +19,8 @@ Then build and copy all specs to [`modules/generated/`](./modules/generated/):
nix build '.#jobs.x86_64-linux.generators.k8s'
cp ./result/* modules/generated/
Now add the version in [`./modules/k8s.nix`](./modules/k8s.nix) under `options.kubernetes.version.type` as well as a new check in [`./flake.nix`](./flake.nix) (e.g., `tests-k8s-1_23`).
## Tests
Tests are executed through GitHub actions; see the [workflow definition](../kubenix/.github/workflows/ci.yml) for commands.

View file

@ -95,6 +95,7 @@
tests-k8s-1_20 = wasSuccess (mkK8STests {k8sVersion = "1.20";});
tests-k8s-1_21 = wasSuccess (mkK8STests {k8sVersion = "1.21";});
tests-k8s-1_23 = wasSuccess (mkK8STests {k8sVersion = "1.23";});
tests-k8s-1_24 = wasSuccess (mkK8STests {k8sVersion = "1.24";});
};
}
))

View file

@ -272,8 +272,8 @@ in {
options.kubernetes = {
version = mkOption {
description = "Kubernetes version to use";
type = types.enum ["1.19" "1.20" "1.21" "1.23"];
default = "1.23";
type = types.enum ["1.19" "1.20" "1.21" "1.23" "1.24"];
default = "1.24";
};
namespace = mkOption {