nixos/kubernetes: dashboard 1.8.3 -> 1.10.1

- add option to specify extra cmdline arguments to the dashboard
This commit is contained in:
Johan Thomsen 2019-02-18 15:08:52 +01:00
parent 5af74e19e6
commit f738618637

View File

@ -8,6 +8,13 @@ in {
options.services.kubernetes.addons.dashboard = { options.services.kubernetes.addons.dashboard = {
enable = mkEnableOption "kubernetes dashboard addon"; enable = mkEnableOption "kubernetes dashboard addon";
extraArgs = mkOption {
description = "Extra arguments to append to the dashboard cmdline";
type = types.listOf types.str;
default = [];
example = ["--enable-skip-login"];
};
rbac = mkOption { rbac = mkOption {
description = "Role-based access control (RBAC) options"; description = "Role-based access control (RBAC) options";
default = {}; default = {};
@ -31,7 +38,7 @@ in {
version = mkOption { version = mkOption {
description = "Which version of the kubernetes dashboard to deploy"; description = "Which version of the kubernetes dashboard to deploy";
type = types.str; type = types.str;
default = "v1.8.3"; default = "v1.10.1";
}; };
image = mkOption { image = mkOption {
@ -39,9 +46,9 @@ in {
type = types.attrs; type = types.attrs;
default = { default = {
imageName = "k8s.gcr.io/kubernetes-dashboard-amd64"; imageName = "k8s.gcr.io/kubernetes-dashboard-amd64";
imageDigest = "sha256:dc4026c1b595435ef5527ca598e1e9c4343076926d7d62b365c44831395adbd0"; imageDigest = "sha256:0ae6b69432e78069c5ce2bcde0fe409c5c4d6f0f4d9cd50a17974fea38898747";
finalImageTag = cfg.version; finalImageTag = cfg.version;
sha256 = "18ajcg0q1vignfjk2sm4xj4wzphfz8wah69ps8dklqfvv0164mc8"; sha256 = "01xrr4pwgr2hcjrjsi3d14ifpzdfbxzqpzxbk2fkbjb9zkv38zxy";
}; };
}; };
}; };
@ -99,7 +106,7 @@ in {
memory = "100Mi"; memory = "100Mi";
}; };
}; };
args = ["--auto-generate-certificates"]; args = ["--auto-generate-certificates"] ++ cfg.extraArgs;
volumeMounts = [{ volumeMounts = [{
name = "tmp-volume"; name = "tmp-volume";
mountPath = "/tmp"; mountPath = "/tmp";