From 6c186ae31d4967d96d9d5f1c1d7a78e481cb83dd Mon Sep 17 00:00:00 2001 From: Vladimir Varankin Date: Fri, 10 Jan 2025 15:45:35 +0100 Subject: [PATCH] mimir-distributed: allow components to override their container image (#10340) * mimir-distributed: allow components to override their container image Signed-off-by: Vladimir Varankin * add test values Signed-off-by: Vladimir Varankin * rebuild assets Signed-off-by: Vladimir Varankin * update changelog Signed-off-by: Vladimir Varankin * update code comments Signed-off-by: Vladimir Varankin * add default values for component images Signed-off-by: Vladimir Varankin * update changelog Signed-off-by: Vladimir Varankin * rebuild assets Signed-off-by: Vladimir Varankin * fix how build script removes default image from generated manifest Signed-off-by: Vladimir Varankin * rebuild assets Signed-off-by: Vladimir Varankin * update values comments Signed-off-by: Vladimir Varankin --------- Signed-off-by: Vladimir Varankin --- .../charts/mimir-distributed/CHANGELOG.md | 1 + ...est-enterprise-component-image-values.yaml | 97 ++++ .../test-oss-component-image-values.yaml | 84 ++++ .../mimir-distributed/templates/_helpers.tpl | 14 +- .../templates/admin-api/admin-api-dep.yaml | 2 +- .../alertmanager/alertmanager-dep.yaml | 2 +- .../alertmanager-statefulset.yaml | 2 +- .../compactor/compactor-statefulset.yaml | 2 +- .../continuous_test/continuous-test-dep.yaml | 2 +- .../distributor/distributor-dep.yaml | 2 +- .../federation-frontend-dep.yaml | 2 +- .../templates/gateway/gateway-dep.yaml | 2 +- .../graphite-querier-dep.yaml | 2 +- .../graphite-write-proxy-dep.yaml | 2 +- .../ingester/ingester-statefulset.yaml | 2 +- .../overrides-exporter-dep.yaml | 2 +- .../templates/querier/querier-dep.yaml | 2 +- .../query-frontend/query-frontend-dep.yaml | 2 +- .../query-scheduler/query-scheduler-dep.yaml | 2 +- .../ruler-querier/ruler-querier-dep.yaml | 2 +- .../ruler-query-frontend-dep.yaml | 2 +- .../ruler-query-scheduler-dep.yaml | 2 +- .../templates/ruler/ruler-dep.yaml | 2 +- .../templates/smoke-test/smoke-test-job.yaml | 2 +- .../store-gateway-statefulset.yaml | 2 +- .../templates/tokengen/tokengen-job.yaml | 2 +- .../helm/charts/mimir-distributed/values.yaml | 110 +++++ operations/helm/scripts/build.sh | 2 +- .../templates/deployment.yaml | 65 +++ .../rollout_operator/templates/role.yaml | 36 ++ .../templates/rolebinding.yaml | 19 + .../templates/serviceaccount.yaml | 12 + .../templates/admin-api/admin-api-dep.yaml | 119 +++++ .../templates/admin-api/admin-api-pdb.yaml | 19 + .../templates/admin-api/admin-api-svc.yaml | 30 ++ .../alertmanager/alertmanager-config.yaml | 21 + .../alertmanager/alertmanager-pdb.yaml | 19 + .../alertmanager-statefulset.yaml | 139 ++++++ .../alertmanager-svc-headless.yaml | 36 ++ .../alertmanager/alertmanager-svc.yaml | 30 ++ .../templates/compactor/compactor-pdb.yaml | 19 + .../compactor/compactor-statefulset.yaml | 127 ++++++ .../templates/compactor/compactor-svc.yaml | 30 ++ .../distributor/distributor-dep.yaml | 132 ++++++ .../distributor/distributor-pdb.yaml | 19 + .../distributor/distributor-svc-headless.yaml | 32 ++ .../distributor/distributor-svc.yaml | 30 ++ .../federation-frontend-dep.yaml | 96 ++++ .../federation-frontend-pdb.yaml | 19 + .../federation-frontend-svc.yaml | 29 ++ .../templates/gateway/gateway-dep.yaml | 110 +++++ .../templates/gateway/gateway-pdb.yaml | 19 + .../templates/gateway/gateway-svc.yaml | 29 ++ .../gossip-ring/gossip-ring-svc.yaml | 26 ++ .../templates/ingester/ingester-pdb.yaml | 19 + .../ingester/ingester-statefulset.yaml | 426 +++++++++++++++++ .../ingester/ingester-svc-headless.yaml | 32 ++ .../templates/ingester/ingester-svc.yaml | 105 +++++ .../templates/license-secret.yaml | 13 + .../templates/mimir-config.yaml | 137 ++++++ .../overrides-exporter-dep.yaml | 109 +++++ .../overrides-exporter-pdb.yaml | 19 + .../overrides-exporter-svc.yaml | 29 ++ .../templates/podsecuritypolicy.yaml | 40 ++ .../templates/querier/querier-dep.yaml | 124 +++++ .../templates/querier/querier-pdb.yaml | 19 + .../templates/querier/querier-svc.yaml | 30 ++ .../query-frontend/query-frontend-dep.yaml | 121 +++++ .../query-frontend/query-frontend-pdb.yaml | 19 + .../query-frontend/query-frontend-svc.yaml | 29 ++ .../query-scheduler/query-scheduler-dep.yaml | 113 +++++ .../query-scheduler/query-scheduler-pdb.yaml | 19 + .../query-scheduler-svc-headless.yaml | 32 ++ .../query-scheduler/query-scheduler-svc.yaml | 29 ++ .../mimir-distributed/templates/role.yaml | 16 + .../templates/rolebinding.yaml | 20 + .../templates/ruler/ruler-dep.yaml | 123 +++++ .../templates/ruler/ruler-pdb.yaml | 19 + .../templates/ruler/ruler-svc.yaml | 26 ++ .../templates/runtime-configmap.yaml | 15 + .../templates/serviceaccount.yaml | 13 + .../store-gateway/store-gateway-pdb.yaml | 19 + .../store-gateway-statefulset.yaml | 429 ++++++++++++++++++ .../store-gateway-svc-headless.yaml | 32 ++ .../store-gateway/store-gateway-svc.yaml | 105 +++++ .../templates/tokengen/tokengen-job.yaml | 74 +++ .../templates/deployment.yaml | 65 +++ .../rollout_operator/templates/role.yaml | 36 ++ .../templates/rolebinding.yaml | 19 + .../templates/serviceaccount.yaml | 12 + .../alertmanager/alertmanager-config.yaml | 21 + .../alertmanager/alertmanager-pdb.yaml | 19 + .../alertmanager-statefulset.yaml | 134 ++++++ .../alertmanager-svc-headless.yaml | 36 ++ .../alertmanager/alertmanager-svc.yaml | 30 ++ .../templates/compactor/compactor-pdb.yaml | 19 + .../compactor/compactor-statefulset.yaml | 122 +++++ .../templates/compactor/compactor-svc.yaml | 30 ++ .../distributor/distributor-dep.yaml | 127 ++++++ .../distributor/distributor-pdb.yaml | 19 + .../distributor/distributor-svc-headless.yaml | 32 ++ .../distributor/distributor-svc.yaml | 30 ++ .../gossip-ring/gossip-ring-svc.yaml | 26 ++ .../templates/ingester/ingester-pdb.yaml | 19 + .../ingester/ingester-statefulset.yaml | 411 +++++++++++++++++ .../ingester/ingester-svc-headless.yaml | 32 ++ .../templates/ingester/ingester-svc.yaml | 105 +++++ .../templates/mimir-config.yaml | 96 ++++ .../templates/nginx/nginx-configmap.yaml | 138 ++++++ .../templates/nginx/nginx-dep.yaml | 92 ++++ .../templates/nginx/nginx-pdb.yaml | 19 + .../templates/nginx/nginx-svc.yaml | 25 + .../overrides-exporter-dep.yaml | 104 +++++ .../overrides-exporter-pdb.yaml | 19 + .../overrides-exporter-svc.yaml | 29 ++ .../templates/podsecuritypolicy.yaml | 40 ++ .../templates/querier/querier-dep.yaml | 119 +++++ .../templates/querier/querier-pdb.yaml | 19 + .../templates/querier/querier-svc.yaml | 30 ++ .../query-frontend/query-frontend-dep.yaml | 116 +++++ .../query-frontend/query-frontend-pdb.yaml | 19 + .../query-frontend/query-frontend-svc.yaml | 29 ++ .../query-scheduler/query-scheduler-dep.yaml | 108 +++++ .../query-scheduler/query-scheduler-pdb.yaml | 19 + .../query-scheduler-svc-headless.yaml | 32 ++ .../query-scheduler/query-scheduler-svc.yaml | 29 ++ .../mimir-distributed/templates/role.yaml | 16 + .../templates/rolebinding.yaml | 20 + .../templates/ruler/ruler-dep.yaml | 118 +++++ .../templates/ruler/ruler-pdb.yaml | 19 + .../templates/ruler/ruler-svc.yaml | 26 ++ .../templates/runtime-configmap.yaml | 15 + .../templates/serviceaccount.yaml | 13 + .../templates/smoke-test/smoke-test-job.yaml | 54 +++ .../store-gateway/store-gateway-pdb.yaml | 19 + .../store-gateway-statefulset.yaml | 414 +++++++++++++++++ .../store-gateway-svc-headless.yaml | 32 ++ .../store-gateway/store-gateway-svc.yaml | 105 +++++ 138 files changed, 7221 insertions(+), 25 deletions(-) create mode 100644 operations/helm/charts/mimir-distributed/ci/offline/test-enterprise-component-image-values.yaml create mode 100644 operations/helm/charts/mimir-distributed/ci/offline/test-oss-component-image-values.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/charts/rollout_operator/templates/deployment.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/charts/rollout_operator/templates/role.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/charts/rollout_operator/templates/rolebinding.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/charts/rollout_operator/templates/serviceaccount.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/admin-api/admin-api-dep.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/admin-api/admin-api-pdb.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/admin-api/admin-api-svc.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-config.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-pdb.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-statefulset.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-svc-headless.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-svc.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/compactor/compactor-pdb.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/compactor/compactor-statefulset.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/compactor/compactor-svc.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/distributor/distributor-dep.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/distributor/distributor-pdb.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/distributor/distributor-svc-headless.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/distributor/distributor-svc.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/federation-frontend/federation-frontend-dep.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/federation-frontend/federation-frontend-pdb.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/federation-frontend/federation-frontend-svc.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/gateway/gateway-dep.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/gateway/gateway-pdb.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/gateway/gateway-svc.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/gossip-ring/gossip-ring-svc.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/ingester/ingester-pdb.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/ingester/ingester-statefulset.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/ingester/ingester-svc-headless.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/ingester/ingester-svc.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/license-secret.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/mimir-config.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/overrides-exporter/overrides-exporter-dep.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/overrides-exporter/overrides-exporter-pdb.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/overrides-exporter/overrides-exporter-svc.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/podsecuritypolicy.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/querier/querier-dep.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/querier/querier-pdb.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/querier/querier-svc.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/query-frontend/query-frontend-dep.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/query-frontend/query-frontend-pdb.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/query-frontend/query-frontend-svc.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/query-scheduler/query-scheduler-dep.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/query-scheduler/query-scheduler-pdb.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/query-scheduler/query-scheduler-svc-headless.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/query-scheduler/query-scheduler-svc.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/role.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/rolebinding.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/ruler/ruler-dep.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/ruler/ruler-pdb.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/ruler/ruler-svc.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/runtime-configmap.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/serviceaccount.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/store-gateway/store-gateway-pdb.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/store-gateway/store-gateway-statefulset.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/store-gateway/store-gateway-svc-headless.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/store-gateway/store-gateway-svc.yaml create mode 100644 operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/tokengen/tokengen-job.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/charts/rollout_operator/templates/deployment.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/charts/rollout_operator/templates/role.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/charts/rollout_operator/templates/rolebinding.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/charts/rollout_operator/templates/serviceaccount.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-config.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-pdb.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-statefulset.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-svc-headless.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-svc.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/compactor/compactor-pdb.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/compactor/compactor-statefulset.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/compactor/compactor-svc.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/distributor/distributor-dep.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/distributor/distributor-pdb.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/distributor/distributor-svc-headless.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/distributor/distributor-svc.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/gossip-ring/gossip-ring-svc.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/ingester/ingester-pdb.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/ingester/ingester-statefulset.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/ingester/ingester-svc-headless.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/ingester/ingester-svc.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/mimir-config.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/nginx/nginx-configmap.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/nginx/nginx-dep.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/nginx/nginx-pdb.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/nginx/nginx-svc.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/overrides-exporter/overrides-exporter-dep.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/overrides-exporter/overrides-exporter-pdb.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/overrides-exporter/overrides-exporter-svc.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/podsecuritypolicy.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/querier/querier-dep.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/querier/querier-pdb.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/querier/querier-svc.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/query-frontend/query-frontend-dep.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/query-frontend/query-frontend-pdb.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/query-frontend/query-frontend-svc.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/query-scheduler/query-scheduler-dep.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/query-scheduler/query-scheduler-pdb.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/query-scheduler/query-scheduler-svc-headless.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/query-scheduler/query-scheduler-svc.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/role.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/rolebinding.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/ruler/ruler-dep.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/ruler/ruler-pdb.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/ruler/ruler-svc.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/runtime-configmap.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/serviceaccount.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/smoke-test/smoke-test-job.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/store-gateway/store-gateway-pdb.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/store-gateway/store-gateway-statefulset.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/store-gateway/store-gateway-svc-headless.yaml create mode 100644 operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/store-gateway/store-gateway-svc.yaml diff --git a/operations/helm/charts/mimir-distributed/CHANGELOG.md b/operations/helm/charts/mimir-distributed/CHANGELOG.md index d342540d313..a3f3f6cc2bc 100644 --- a/operations/helm/charts/mimir-distributed/CHANGELOG.md +++ b/operations/helm/charts/mimir-distributed/CHANGELOG.md @@ -31,6 +31,7 @@ Entries should include a reference to the Pull Request that introduced the chang * [CHANGE] Memcached: Update to Memcached 1.6.34. #10318 * [ENHANCEMENT] Minio: update subchart to v5.4.0. #10346 +* [ENHANCEMENT] Individual mimir components can override their container images via the *.image values. The component's image definitions always override the values set in global `image` or `enterprise.image`. #10340 * [BUGFIX] Fix calculation of `mimir.siToBytes` and use floating point arithmetics. #10044 ## 5.6.0-rc.0 diff --git a/operations/helm/charts/mimir-distributed/ci/offline/test-enterprise-component-image-values.yaml b/operations/helm/charts/mimir-distributed/ci/offline/test-enterprise-component-image-values.yaml new file mode 100644 index 00000000000..527377162ed --- /dev/null +++ b/operations/helm/charts/mimir-distributed/ci/offline/test-enterprise-component-image-values.yaml @@ -0,0 +1,97 @@ +# General setup +enterprise: + enabled: true +minio: + enabled: false + +# Individual components under test +admin_api: + image: + repository: test/admin-api + tag: 1-admin-api + +alertmanager: + image: + repository: test/alertmanager + tag: 1-alertmanager + +compactor: + image: + repository: test/compactor + tag: 1-compactor + +continuous_test: + image: + repository: test/continuous_test + tag: 1-continuous-test + +distributor: + image: + repository: test/distributor + tag: 1-distributor + +federation_frontend: + enabled: true + image: + repository: test/federation_frontend + tag: 1-federation-frontend + +gateway: + image: + repository: test/gateway + tag: 1-gateway + +ingester: + image: + repository: test/ingester + tag: 1-ingester + +overrides_exporter: + image: + repository: test/overrides_exporter + tag: 1-overrides-exporter + +querier: + image: + repository: test/querier + tag: 1-querier + +query_frontend: + image: + repository: test/query_frontend + tag: 1-query-frontend + +query_scheduler: + image: + repository: test/query_scheduler + tag: 1-query-scheduler + +ruler: + image: + repository: test/ruler + tag: 1-ruler + +ruler_querier: + image: + repository: test/ruler_querier + tag: 1-ruler-querier + +ruler_query_frontend: + image: + repository: test/ruler_query_frontend + tag: 1-ruler-query-frontend + +ruler_query_scheduler: + image: + repository: test/ruler_query_scheduler + tag: 1-ruler-query-scheduler + +smoke_test: + image: + repository: test/smoke_test + tag: 1-smoke-test + +store_gateway: + image: + repository: test/store_gateway + tag: 1-store-gateway diff --git a/operations/helm/charts/mimir-distributed/ci/offline/test-oss-component-image-values.yaml b/operations/helm/charts/mimir-distributed/ci/offline/test-oss-component-image-values.yaml new file mode 100644 index 00000000000..3d5bb2fcee8 --- /dev/null +++ b/operations/helm/charts/mimir-distributed/ci/offline/test-oss-component-image-values.yaml @@ -0,0 +1,84 @@ +# General setup +minio: + enabled: false + +# Individual components under test +alertmanager: + image: + repository: test/alertmanager + tag: 1-alertmanager + +compactor: + image: + repository: test/compactor + tag: 1-compactor + +continuous_test: + image: + repository: test/continuous_test + tag: 1-continuous-test + +distributor: + image: + repository: test/distributor + tag: 1-distributor + +gateway: + image: + repository: test/gateway + tag: 1-gateway + +ingester: + image: + repository: test/ingester + tag: 1-ingester + +overrides_exporter: + image: + repository: test/overrides_exporter + tag: 1-overrides-exporter + +querier: + image: + repository: test/querier + tag: 1-querier + +query_frontend: + image: + repository: test/query_frontend + tag: 1-query-frontend + +query_scheduler: + image: + repository: test/query_scheduler + tag: 1-query-scheduler + +ruler: + image: + repository: test/ruler + tag: 1-ruler + +ruler_querier: + image: + repository: test/ruler_querier + tag: 1-ruler-querier + +ruler_query_frontend: + image: + repository: test/ruler_query_frontend + tag: 1-ruler-query-frontend + +ruler_query_scheduler: + image: + repository: test/ruler_query_scheduler + tag: 1-ruler-query-scheduler + +smoke_test: + image: + repository: test/smoke_test + tag: 1-smoke-test + +store_gateway: + image: + repository: test/store_gateway + tag: 1-store-gateway diff --git a/operations/helm/charts/mimir-distributed/templates/_helpers.tpl b/operations/helm/charts/mimir-distributed/templates/_helpers.tpl index 34b5a998805..a661a8c84b3 100644 --- a/operations/helm/charts/mimir-distributed/templates/_helpers.tpl +++ b/operations/helm/charts/mimir-distributed/templates/_helpers.tpl @@ -50,10 +50,20 @@ Create chart name and version as used by the chart label. {{- end -}} {{/* -Calculate image name based on whether enterprise features are requested +Build mimir image reference based on whether enterprise features are requested. The component local values always take precedence. +Params: + ctx = . context + component = component name */}} {{- define "mimir.imageReference" -}} -{{- if .Values.enterprise.enabled -}}{{ .Values.enterprise.image.repository }}:{{ .Values.enterprise.image.tag }}{{- else -}}{{ .Values.image.repository }}:{{ .Values.image.tag }}{{- end -}} +{{- $componentSection := include "mimir.componentSectionFromName" . | fromYaml -}} +{{- $image := $componentSection.image | default dict -}} +{{- if .ctx.Values.enterprise.enabled -}} + {{- $image = mustMerge $image .ctx.Values.enterprise.image -}} +{{- else -}} + {{- $image = mustMerge $image .ctx.Values.image -}} +{{- end -}} +{{ $image.repository }}:{{ $image.tag }} {{- end -}} {{/* diff --git a/operations/helm/charts/mimir-distributed/templates/admin-api/admin-api-dep.yaml b/operations/helm/charts/mimir-distributed/templates/admin-api/admin-api-dep.yaml index a59e56f8efe..69941aa34e8 100644 --- a/operations/helm/charts/mimir-distributed/templates/admin-api/admin-api-dep.yaml +++ b/operations/helm/charts/mimir-distributed/templates/admin-api/admin-api-dep.yaml @@ -41,7 +41,7 @@ spec: {{- end }} containers: - name: admin-api - image: "{{ include "mimir.imageReference" . }}" + image: {{ include "mimir.imageReference" (dict "ctx" . "component" "admin-api") }} imagePullPolicy: {{ .Values.image.pullPolicy }} args: - "-target=admin-api" diff --git a/operations/helm/charts/mimir-distributed/templates/alertmanager/alertmanager-dep.yaml b/operations/helm/charts/mimir-distributed/templates/alertmanager/alertmanager-dep.yaml index f598c211aaf..ccf367000b9 100644 --- a/operations/helm/charts/mimir-distributed/templates/alertmanager/alertmanager-dep.yaml +++ b/operations/helm/charts/mimir-distributed/templates/alertmanager/alertmanager-dep.yaml @@ -45,7 +45,7 @@ spec: {{- end }} containers: - name: alertmanager - image: "{{ include "mimir.imageReference" . }}" + image: {{ include "mimir.imageReference" (dict "ctx" . "component" "alertmanager") }} imagePullPolicy: {{ .Values.image.pullPolicy }} args: - "-target=alertmanager" diff --git a/operations/helm/charts/mimir-distributed/templates/alertmanager/alertmanager-statefulset.yaml b/operations/helm/charts/mimir-distributed/templates/alertmanager/alertmanager-statefulset.yaml index b59fd86aaef..68fb3b30f52 100644 --- a/operations/helm/charts/mimir-distributed/templates/alertmanager/alertmanager-statefulset.yaml +++ b/operations/helm/charts/mimir-distributed/templates/alertmanager/alertmanager-statefulset.yaml @@ -135,7 +135,7 @@ spec: {{ toYaml .Values.alertmanager.extraContainers | nindent 8 }} {{- end }} - name: alertmanager - image: "{{ include "mimir.imageReference" . }}" + image: {{ include "mimir.imageReference" (dict "ctx" . "component" "alertmanager") }} imagePullPolicy: {{ .Values.image.pullPolicy }} args: - "-target=alertmanager" diff --git a/operations/helm/charts/mimir-distributed/templates/compactor/compactor-statefulset.yaml b/operations/helm/charts/mimir-distributed/templates/compactor/compactor-statefulset.yaml index c13b2c148cf..b8a451373fd 100644 --- a/operations/helm/charts/mimir-distributed/templates/compactor/compactor-statefulset.yaml +++ b/operations/helm/charts/mimir-distributed/templates/compactor/compactor-statefulset.yaml @@ -115,7 +115,7 @@ spec: {{ toYaml .Values.compactor.extraContainers | nindent 8 }} {{- end }} - name: compactor - image: "{{ include "mimir.imageReference" . }}" + image: {{ include "mimir.imageReference" (dict "ctx" . "component" "compactor") }} imagePullPolicy: {{ .Values.image.pullPolicy }} args: - "-target=compactor" diff --git a/operations/helm/charts/mimir-distributed/templates/continuous_test/continuous-test-dep.yaml b/operations/helm/charts/mimir-distributed/templates/continuous_test/continuous-test-dep.yaml index 6cd407999ee..9e8e41734ac 100644 --- a/operations/helm/charts/mimir-distributed/templates/continuous_test/continuous-test-dep.yaml +++ b/operations/helm/charts/mimir-distributed/templates/continuous_test/continuous-test-dep.yaml @@ -41,7 +41,7 @@ spec: {{- end }} containers: - name: continuous-test - image: "{{ include "mimir.imageReference" . }}" + image: {{ include "mimir.imageReference" (dict "ctx" . "component" "continuous-test") }} imagePullPolicy: {{ .Values.image.pullPolicy }} args: - "-target=continuous-test" diff --git a/operations/helm/charts/mimir-distributed/templates/distributor/distributor-dep.yaml b/operations/helm/charts/mimir-distributed/templates/distributor/distributor-dep.yaml index d7b21c3d171..52b855c427e 100644 --- a/operations/helm/charts/mimir-distributed/templates/distributor/distributor-dep.yaml +++ b/operations/helm/charts/mimir-distributed/templates/distributor/distributor-dep.yaml @@ -46,7 +46,7 @@ spec: {{- end }} containers: - name: distributor - image: "{{ include "mimir.imageReference" . }}" + image: {{ include "mimir.imageReference" (dict "ctx" . "component" "distributor") }} imagePullPolicy: {{ .Values.image.pullPolicy }} args: - "-target=distributor" diff --git a/operations/helm/charts/mimir-distributed/templates/federation-frontend/federation-frontend-dep.yaml b/operations/helm/charts/mimir-distributed/templates/federation-frontend/federation-frontend-dep.yaml index f7fdf266e39..fda0e01403d 100644 --- a/operations/helm/charts/mimir-distributed/templates/federation-frontend/federation-frontend-dep.yaml +++ b/operations/helm/charts/mimir-distributed/templates/federation-frontend/federation-frontend-dep.yaml @@ -40,7 +40,7 @@ spec: {{- end }} containers: - name: federation-frontend - image: {{ include "mimir.imageReference" . | quote }} + image: {{ include "mimir.imageReference" (dict "ctx" . "component" "federation-frontend") }} imagePullPolicy: {{ .Values.image.pullPolicy }} args: - "-target=federation-frontend" diff --git a/operations/helm/charts/mimir-distributed/templates/gateway/gateway-dep.yaml b/operations/helm/charts/mimir-distributed/templates/gateway/gateway-dep.yaml index 06652007ceb..86c2d89d983 100644 --- a/operations/helm/charts/mimir-distributed/templates/gateway/gateway-dep.yaml +++ b/operations/helm/charts/mimir-distributed/templates/gateway/gateway-dep.yaml @@ -52,7 +52,7 @@ spec: containers: {{- if $isGEMGateway }} - name: gateway - image: {{ include "mimir.imageReference" $ | quote }} + image: {{ include "mimir.imageReference" (dict "ctx" $ "component" "gateway") }} imagePullPolicy: {{ $.Values.image.pullPolicy }} args: - "-target=gateway" diff --git a/operations/helm/charts/mimir-distributed/templates/graphite-proxy/graphite-querier/graphite-querier-dep.yaml b/operations/helm/charts/mimir-distributed/templates/graphite-proxy/graphite-querier/graphite-querier-dep.yaml index ea406df65d6..1e0d9180ece 100644 --- a/operations/helm/charts/mimir-distributed/templates/graphite-proxy/graphite-querier/graphite-querier-dep.yaml +++ b/operations/helm/charts/mimir-distributed/templates/graphite-proxy/graphite-querier/graphite-querier-dep.yaml @@ -44,7 +44,7 @@ spec: {{ toYaml .Values.graphite.querier.extraContainers | nindent 8 }} {{- end }} - name: graphite-querier - image: {{ include "mimir.imageReference" . | quote }} + image: {{ include "mimir.imageReference" (dict "ctx" . "component" "graphite-querier") }} imagePullPolicy: {{ .Values.image.pullPolicy }} args: - -target=graphite-querier diff --git a/operations/helm/charts/mimir-distributed/templates/graphite-proxy/graphite-write-proxy/graphite-write-proxy-dep.yaml b/operations/helm/charts/mimir-distributed/templates/graphite-proxy/graphite-write-proxy/graphite-write-proxy-dep.yaml index 4aae8c5ee8a..d01df659eab 100644 --- a/operations/helm/charts/mimir-distributed/templates/graphite-proxy/graphite-write-proxy/graphite-write-proxy-dep.yaml +++ b/operations/helm/charts/mimir-distributed/templates/graphite-proxy/graphite-write-proxy/graphite-write-proxy-dep.yaml @@ -44,7 +44,7 @@ spec: {{ toYaml .Values.graphite.write_proxy.extraContainers | nindent 8 }} {{- end }} - name: graphite-write-proxy - image: "{{ include "mimir.imageReference" . }}" + image: {{ include "mimir.imageReference" (dict "ctx" . "component" "graphite-write-proxy") }} imagePullPolicy: {{ .Values.image.pullPolicy }} args: - -target=graphite-write-proxy diff --git a/operations/helm/charts/mimir-distributed/templates/ingester/ingester-statefulset.yaml b/operations/helm/charts/mimir-distributed/templates/ingester/ingester-statefulset.yaml index e6e27a223e9..d13a949f46b 100644 --- a/operations/helm/charts/mimir-distributed/templates/ingester/ingester-statefulset.yaml +++ b/operations/helm/charts/mimir-distributed/templates/ingester/ingester-statefulset.yaml @@ -125,7 +125,7 @@ spec: {{ toYaml .Values.ingester.extraContainers | nindent 8 }} {{- end }} - name: ingester - image: "{{ include "mimir.imageReference" . }}" + image: {{ include "mimir.imageReference" (dict "ctx" . "component" "ingester") }} imagePullPolicy: {{ .Values.image.pullPolicy }} args: - "-target=ingester" diff --git a/operations/helm/charts/mimir-distributed/templates/overrides-exporter/overrides-exporter-dep.yaml b/operations/helm/charts/mimir-distributed/templates/overrides-exporter/overrides-exporter-dep.yaml index ac8dc5e7525..06d4a382978 100644 --- a/operations/helm/charts/mimir-distributed/templates/overrides-exporter/overrides-exporter-dep.yaml +++ b/operations/helm/charts/mimir-distributed/templates/overrides-exporter/overrides-exporter-dep.yaml @@ -41,7 +41,7 @@ spec: {{- end }} containers: - name: overrides-exporter - image: "{{ include "mimir.imageReference" . }}" + image: {{ include "mimir.imageReference" (dict "ctx" . "component" "overrides-exporter") }} imagePullPolicy: {{ .Values.image.pullPolicy }} args: - "-target=overrides-exporter" diff --git a/operations/helm/charts/mimir-distributed/templates/querier/querier-dep.yaml b/operations/helm/charts/mimir-distributed/templates/querier/querier-dep.yaml index ce5f4a825fa..168bf6b9e71 100644 --- a/operations/helm/charts/mimir-distributed/templates/querier/querier-dep.yaml +++ b/operations/helm/charts/mimir-distributed/templates/querier/querier-dep.yaml @@ -45,7 +45,7 @@ spec: {{- end }} containers: - name: querier - image: "{{ include "mimir.imageReference" . }}" + image: {{ include "mimir.imageReference" (dict "ctx" . "component" "querier") }} imagePullPolicy: {{ .Values.image.pullPolicy }} args: - "-target=querier" diff --git a/operations/helm/charts/mimir-distributed/templates/query-frontend/query-frontend-dep.yaml b/operations/helm/charts/mimir-distributed/templates/query-frontend/query-frontend-dep.yaml index 96f0e911478..31981b6b284 100644 --- a/operations/helm/charts/mimir-distributed/templates/query-frontend/query-frontend-dep.yaml +++ b/operations/helm/charts/mimir-distributed/templates/query-frontend/query-frontend-dep.yaml @@ -46,7 +46,7 @@ spec: {{- end }} containers: - name: query-frontend - image: "{{ include "mimir.imageReference" . }}" + image: {{ include "mimir.imageReference" (dict "ctx" . "component" "query-frontend") }} imagePullPolicy: {{ .Values.image.pullPolicy }} args: - "-target=query-frontend" diff --git a/operations/helm/charts/mimir-distributed/templates/query-scheduler/query-scheduler-dep.yaml b/operations/helm/charts/mimir-distributed/templates/query-scheduler/query-scheduler-dep.yaml index 380282ecf80..783c55e3b1e 100644 --- a/operations/helm/charts/mimir-distributed/templates/query-scheduler/query-scheduler-dep.yaml +++ b/operations/helm/charts/mimir-distributed/templates/query-scheduler/query-scheduler-dep.yaml @@ -40,7 +40,7 @@ spec: {{- end }} containers: - name: query-scheduler - image: "{{ include "mimir.imageReference" . }}" + image: {{ include "mimir.imageReference" (dict "ctx" . "component" "query-scheduler") }} imagePullPolicy: {{ .Values.image.pullPolicy }} args: - "-target=query-scheduler" diff --git a/operations/helm/charts/mimir-distributed/templates/ruler-querier/ruler-querier-dep.yaml b/operations/helm/charts/mimir-distributed/templates/ruler-querier/ruler-querier-dep.yaml index 6e17bcdc49e..6d5407a6622 100644 --- a/operations/helm/charts/mimir-distributed/templates/ruler-querier/ruler-querier-dep.yaml +++ b/operations/helm/charts/mimir-distributed/templates/ruler-querier/ruler-querier-dep.yaml @@ -45,7 +45,7 @@ spec: {{- end }} containers: - name: ruler-querier - image: "{{ include "mimir.imageReference" . }}" + image: {{ include "mimir.imageReference" (dict "ctx" . "component" "ruler-querier") }} imagePullPolicy: {{ .Values.image.pullPolicy }} args: - "-target=querier" diff --git a/operations/helm/charts/mimir-distributed/templates/ruler-query-frontend/ruler-query-frontend-dep.yaml b/operations/helm/charts/mimir-distributed/templates/ruler-query-frontend/ruler-query-frontend-dep.yaml index 163bee57b84..73902433018 100644 --- a/operations/helm/charts/mimir-distributed/templates/ruler-query-frontend/ruler-query-frontend-dep.yaml +++ b/operations/helm/charts/mimir-distributed/templates/ruler-query-frontend/ruler-query-frontend-dep.yaml @@ -46,7 +46,7 @@ spec: {{- end }} containers: - name: ruler-query-frontend - image: "{{ include "mimir.imageReference" . }}" + image: {{ include "mimir.imageReference" (dict "ctx" . "component" "ruler-query-frontend") }} imagePullPolicy: {{ .Values.image.pullPolicy }} args: - "-target=query-frontend" diff --git a/operations/helm/charts/mimir-distributed/templates/ruler-query-scheduler/ruler-query-scheduler-dep.yaml b/operations/helm/charts/mimir-distributed/templates/ruler-query-scheduler/ruler-query-scheduler-dep.yaml index fd08e7327f7..f656e8a0fe7 100644 --- a/operations/helm/charts/mimir-distributed/templates/ruler-query-scheduler/ruler-query-scheduler-dep.yaml +++ b/operations/helm/charts/mimir-distributed/templates/ruler-query-scheduler/ruler-query-scheduler-dep.yaml @@ -40,7 +40,7 @@ spec: {{- end }} containers: - name: ruler-query-scheduler - image: "{{ include "mimir.imageReference" . }}" + image: {{ include "mimir.imageReference" (dict "ctx" . "component" "ruler-query-scheduler") }} imagePullPolicy: {{ .Values.image.pullPolicy }} args: - "-target=query-scheduler" diff --git a/operations/helm/charts/mimir-distributed/templates/ruler/ruler-dep.yaml b/operations/helm/charts/mimir-distributed/templates/ruler/ruler-dep.yaml index bba58d3f7f1..c90d46cc9f0 100644 --- a/operations/helm/charts/mimir-distributed/templates/ruler/ruler-dep.yaml +++ b/operations/helm/charts/mimir-distributed/templates/ruler/ruler-dep.yaml @@ -43,7 +43,7 @@ spec: {{- end }} containers: - name: ruler - image: "{{ include "mimir.imageReference" . }}" + image: {{ include "mimir.imageReference" (dict "ctx" . "component" "ruler") }} imagePullPolicy: {{ .Values.image.pullPolicy }} args: - "-target=ruler" diff --git a/operations/helm/charts/mimir-distributed/templates/smoke-test/smoke-test-job.yaml b/operations/helm/charts/mimir-distributed/templates/smoke-test/smoke-test-job.yaml index ba0157c2a39..55e8adbef81 100644 --- a/operations/helm/charts/mimir-distributed/templates/smoke-test/smoke-test-job.yaml +++ b/operations/helm/charts/mimir-distributed/templates/smoke-test/smoke-test-job.yaml @@ -37,7 +37,7 @@ spec: {{- toYaml .Values.smoke_test.initContainers | nindent 8 }} containers: - name: smoke-test - image: "{{ include "mimir.imageReference" . }}" + image: {{ include "mimir.imageReference" (dict "ctx" . "component" "smoke-test") }} imagePullPolicy: {{ .Values.image.pullPolicy }} args: - "-target=continuous-test" diff --git a/operations/helm/charts/mimir-distributed/templates/store-gateway/store-gateway-statefulset.yaml b/operations/helm/charts/mimir-distributed/templates/store-gateway/store-gateway-statefulset.yaml index 5768bfc3e37..43bf4f3f025 100644 --- a/operations/helm/charts/mimir-distributed/templates/store-gateway/store-gateway-statefulset.yaml +++ b/operations/helm/charts/mimir-distributed/templates/store-gateway/store-gateway-statefulset.yaml @@ -125,7 +125,7 @@ spec: {{ toYaml .Values.store_gateway.extraContainers | nindent 8 }} {{- end }} - name: store-gateway - image: "{{ include "mimir.imageReference" . }}" + image: {{ include "mimir.imageReference" (dict "ctx" . "component" "store-gateway") }} imagePullPolicy: {{ .Values.image.pullPolicy }} args: - "-target=store-gateway" diff --git a/operations/helm/charts/mimir-distributed/templates/tokengen/tokengen-job.yaml b/operations/helm/charts/mimir-distributed/templates/tokengen/tokengen-job.yaml index b8d92686bf8..e157997e7a0 100644 --- a/operations/helm/charts/mimir-distributed/templates/tokengen/tokengen-job.yaml +++ b/operations/helm/charts/mimir-distributed/templates/tokengen/tokengen-job.yaml @@ -40,7 +40,7 @@ spec: {{- toYaml .Values.tokengenJob.initContainers | nindent 8 }} containers: - name: tokengen - image: "{{ include "mimir.imageReference" . }}" + image: {{ include "mimir.imageReference" (dict "ctx" . "component" "tokengen") }} imagePullPolicy: {{ .Values.image.pullPolicy }} args: - "-target=tokengen" diff --git a/operations/helm/charts/mimir-distributed/values.yaml b/operations/helm/charts/mimir-distributed/values.yaml index 4a4f9982f06..ff223192cdd 100644 --- a/operations/helm/charts/mimir-distributed/values.yaml +++ b/operations/helm/charts/mimir-distributed/values.yaml @@ -551,6 +551,12 @@ alertmanager: # E.g. if 'replicas' is set to 4 and there are 3 zones, then 4/3=1.33 and after rounding up it means 2 pods per zone are started. replicas: 1 + # -- Allows to override the container image of the alertmanager component. + # When set it takes precedence over what is defined in global "image" or "enterprise.image" sections. + image: + # repository: grafana/mimir + # tag: 2.15.0 + statefulSet: enabled: true @@ -814,6 +820,12 @@ distributor: # -- Whether to render the manifests related to the distributor component. enabled: true + # -- Allows to override the container image of the distributor component. + # When set it takes precedence over what is defined in global "image" or "enterprise.image" sections. + image: + # repository: grafana/mimir + # tag: 2.15.0 + # Setting it to null will produce a deployment without replicas set, allowing you to use autoscaling with the deployment replicas: 1 @@ -927,6 +939,12 @@ ingester: # -- Whether to render the manifests related to the ingester component. enabled: true + # -- Allows to override the container image of the ingester component. + # When set it takes precedence over what is defined in global "image" or "enterprise.image" sections. + image: + # repository: grafana/mimir + # tag: 2.15.0 + # -- Total number of replicas for the ingester across all availability zones # If ingester.zoneAwareReplication.enabled=false, this number is taken as is. # Otherwise each zone starts `ceil(replicas / number_of_zones)` number of pods. @@ -1152,6 +1170,13 @@ ingester: overrides_exporter: enabled: true + + # -- Allows to override the container image of the overrides-exporter component. + # When set it takes precedence over what is defined in global "image" or "enterprise.image" sections. + image: + # repository: grafana/mimir + # tag: 2.15.0 + replicas: 1 annotations: {} @@ -1241,6 +1266,13 @@ overrides_exporter: ruler: enabled: true + + # -- Allows to override the container image of the ruler component. + # When set it takes precedence over what is defined in global "image" or "enterprise.image" sections. + image: + # repository: grafana/mimir + # tag: 2.15.0 + replicas: 1 # -- [Experimental] Configure autoscaling via KEDA (https://keda.sh). This requires having @@ -1363,6 +1395,12 @@ ruler: # -- Only deployed if .Values.ruler.remoteEvaluationDedicatedQueryPath ruler_querier: + # -- Allows to override the container image of the ruler-querier component. + # When set it takes precedence over what is defined in global "image" or "enterprise.image" sections. + image: + # repository: grafana/mimir + # tag: 2.15.0 + replicas: 2 # -- [Experimental] Configure autoscaling via KEDA (https://keda.sh). This requires having @@ -1481,6 +1519,12 @@ ruler_querier: # -- Only deployed if .Values.ruler.remoteEvaluationDedicatedQueryPath ruler_query_frontend: + # -- Allows to override the container image of the ruler-query-frontend component. + # When set it takes precedence over what is defined in global "image" or "enterprise.image" sections. + image: + # repository: grafana/mimir + # tag: 2.15.0 + # Setting it to null will produce a deployment without replicas set, allowing you to use autoscaling with the deployment replicas: 1 @@ -1591,6 +1635,12 @@ ruler_query_frontend: # -- Only deployed if .Values.ruler.remoteEvaluationDedicatedQueryPath ruler_query_scheduler: + # -- Allows to override the container image of the ruler-query-scheduler component. + # When set it takes precedence over what is defined in global "image" or "enterprise.image" sections. + image: + # repository: grafana/mimir + # tag: 2.15.0 + replicas: 2 service: @@ -1680,6 +1730,12 @@ querier: # -- Whether to render the manifests related to the querier component. enabled: true + # -- Allows to override the container image of the querier component. + # When set it takes precedence over what is defined in global "image" or "enterprise.image" sections. + image: + # repository: grafana/mimir + # tag: 2.15.0 + replicas: 2 # -- [Experimental] Configure autoscaling via KEDA (https://keda.sh). This requires having @@ -1811,6 +1867,12 @@ query_frontend: # -- Whether to render the manifests related to the query-frontend component. enabled: true + # -- Allows to override the container image of the query-frontend component. + # When set it takes precedence over what is defined in global "image" or "enterprise.image" sections. + image: + # repository: grafana/mimir + # tag: 2.15.0 + # Setting it to null will produce a deployment without replicas set, allowing you to use autoscaling with the deployment replicas: 1 @@ -1921,6 +1983,13 @@ query_frontend: query_scheduler: enabled: true + + # -- Allows to override the container image of the query-scheduler component. + # When set it takes precedence over what is defined in global "image" or "enterprise.image" sections. + image: + # repository: grafana/mimir + # tag: 2.15.0 + replicas: 2 service: @@ -2010,6 +2079,12 @@ store_gateway: # -- Whether to render the manifests related to the store-gateway component. enabled: true + # -- Allows to override the container image of the store-gateway component. + # When set it takes precedence over what is defined in global "image" or "enterprise.image" sections. + image: + # repository: grafana/mimir + # tag: 2.15.0 + # -- Total number of replicas for the store-gateway across all availability zones # If store_gateway.zoneAwareReplication.enabled=false, this number is taken as is. # Otherwise each zone starts `ceil(replicas / number_of_zones)` number of pods. @@ -2227,6 +2302,12 @@ compactor: # -- Whether to render the manifests related to the compactor component. enabled: true + # -- Allows to override the container image of the compactor component. + # When set it takes precedence over what is defined in global "image" or "enterprise.image" sections. + image: + # repository: grafana/mimir + # tag: 2.15.0 + replicas: 1 service: @@ -3258,6 +3339,13 @@ gateway: # The value of this field is ignored when gateway.enabled=false. enabledNonEnterprise: false + # -- Allows to override the container image of the gateway component. + # When set it takes precedence over what is defined in global "image" or "enterprise.image" sections. + # Only applies to the GEM gateway. Use gateway.nginx.image for the nginx gateway. + image: + # repository: grafana/mimir-enterprise + # tag: 2.15.0 + # -- Number of replicas for the Deployment replicas: 1 @@ -3990,6 +4078,12 @@ admin_api: # -- Whether to render the manifests related to the admin-api component. enabled: true + # -- Allows to override the container image of the admin-api component. + # When set it takes precedence over what is defined in global "image" or "enterprise.image" sections. + image: + # repository: grafana/enterprise-metrics + # tag: 2.15.0 + replicas: 1 annotations: {} @@ -4466,6 +4560,12 @@ federation_frontend: # -- Specifies whether the federation-frontend should be enabled enabled: false + # -- Allows to override the container image of the federation-frontend component. + # When set it takes precedence over what is defined in global "image" or "enterprise.image" sections. + image: + # repository: grafana/mimir + # tag: 2.15.0 + # -- Specifies whether other components should be deployed. This is an easy way to deploy the resources necessary for a standalone # federation-frontend without the rest of the GEM components. disableOtherComponents: false @@ -4559,6 +4659,11 @@ federation_frontend: # that writing and reading metrics works. Currently not supported for # installations using GEM token-based authentication. smoke_test: + # -- Allows to override the container image of the smoke-test component. + # When set it takes precedence over what is defined in global "image" or "enterprise.image" sections. + image: + # repository: grafana/mimir + # tag: 2.15.0 # -- Controls the backoffLimit on the Kubernetes Job. The Job is marked as failed after that many retries. backoffLimit: 5 # The image section has been removed as continuous test is now a module of the regular Mimir image. @@ -4577,6 +4682,11 @@ smoke_test: # https://grafana.com/docs/mimir/latest/manage/tools/mimir-continuous-test/ continuous_test: enabled: false + # -- Allows to override the container image of the continuous-test component. + # When set it takes precedence over what is defined in global "image" or "enterprise.image" sections. + image: + # repository: grafana/mimir-continuous-test + # tag: 2.15.0 # -- Number of replicas to start of continuous test replicas: 1 # The image section has been removed as continuous test is now a module of the regular Mimir image. diff --git a/operations/helm/scripts/build.sh b/operations/helm/scripts/build.sh index 6178746e95c..e7b9b6922f3 100755 --- a/operations/helm/scripts/build.sh +++ b/operations/helm/scripts/build.sh @@ -83,7 +83,7 @@ function generate_manifests() { helm template "${ARGS[@]}" 1>/dev/null cp -r "${INTERMEDIATE_OUTPUT_DIR}" "${OUTPUT_DIR}" rm "${OUTPUT_DIR}/${CHART_NAME}/templates/values-for-rego-tests.yaml" - find "${OUTPUT_DIR}/${CHART_NAME}/templates" -type f -print0 | xargs -0 "${SED}" -E -i -- "/^\s+(checksum\/(alertmanager-fallback-)?config|(helm.sh\/)?chart|app.kubernetes.io\/version|image: \"grafana\/(mimir|mimir-continuous-test|enterprise-metrics)):/d" + find "${OUTPUT_DIR}/${CHART_NAME}/templates" -type f -print0 | xargs -0 "${SED}" -E -i -- "/^\s+(checksum\/(alertmanager-fallback-)?config|(helm.sh\/)?chart|app.kubernetes.io\/version|image: \"?grafana\/(mimir|mimir-continuous-test|enterprise-metrics)):/d" } for FILEPATH in $TESTS; do diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/charts/rollout_operator/templates/deployment.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/charts/rollout_operator/templates/deployment.yaml new file mode 100644 index 00000000000..e1595094cd4 --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/charts/rollout_operator/templates/deployment.yaml @@ -0,0 +1,65 @@ +--- +# Source: mimir-distributed/charts/rollout_operator/templates/deployment.yaml +apiVersion: apps/v1 +kind: Deployment +metadata: + name: test-enterprise-component-image-values-rollout-operator + labels: + helm.sh/chart: rollout-operator-0.22.0 + app.kubernetes.io/name: rollout-operator + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/version: "v0.22.0" + app.kubernetes.io/managed-by: Helm +spec: + replicas: 1 + minReadySeconds: 10 + selector: + matchLabels: + app.kubernetes.io/name: rollout-operator + app.kubernetes.io/instance: test-enterprise-component-image-values + strategy: + rollingUpdate: + maxSurge: 0 + maxUnavailable: 1 + template: + metadata: + labels: + app.kubernetes.io/name: rollout-operator + app.kubernetes.io/instance: test-enterprise-component-image-values + spec: + serviceAccountName: test-enterprise-component-image-values-rollout-operator + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + containers: + - name: rollout-operator + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true + image: "grafana/rollout-operator:v0.22.0" + imagePullPolicy: IfNotPresent + args: + - -kubernetes.namespace=citestns + ports: + - name: http-metrics + containerPort: 8001 + protocol: TCP + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 5 + timeoutSeconds: 1 + resources: + limits: + memory: 200Mi + requests: + cpu: 100m + memory: 100Mi diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/charts/rollout_operator/templates/role.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/charts/rollout_operator/templates/role.yaml new file mode 100644 index 00000000000..46509b45938 --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/charts/rollout_operator/templates/role.yaml @@ -0,0 +1,36 @@ +--- +# Source: mimir-distributed/charts/rollout_operator/templates/role.yaml +apiVersion: rbac.authorization.k8s.io/v1 +kind: Role +metadata: + name: test-enterprise-component-image-values-rollout-operator + labels: + helm.sh/chart: rollout-operator-0.22.0 + app.kubernetes.io/name: rollout-operator + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/version: "v0.22.0" + app.kubernetes.io/managed-by: Helm +rules: +- apiGroups: + - "" + resources: + - pods + verbs: + - list + - get + - watch + - delete +- apiGroups: + - apps + resources: + - statefulsets + verbs: + - list + - get + - watch +- apiGroups: + - apps + resources: + - statefulsets/status + verbs: + - update diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/charts/rollout_operator/templates/rolebinding.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/charts/rollout_operator/templates/rolebinding.yaml new file mode 100644 index 00000000000..67653825db3 --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/charts/rollout_operator/templates/rolebinding.yaml @@ -0,0 +1,19 @@ +--- +# Source: mimir-distributed/charts/rollout_operator/templates/rolebinding.yaml +apiVersion: rbac.authorization.k8s.io/v1 +kind: RoleBinding +metadata: + name: test-enterprise-component-image-values-rollout-operator + labels: + helm.sh/chart: rollout-operator-0.22.0 + app.kubernetes.io/name: rollout-operator + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/version: "v0.22.0" + app.kubernetes.io/managed-by: Helm +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: Role + name: test-enterprise-component-image-values-rollout-operator +subjects: +- kind: ServiceAccount + name: test-enterprise-component-image-values-rollout-operator diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/charts/rollout_operator/templates/serviceaccount.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/charts/rollout_operator/templates/serviceaccount.yaml new file mode 100644 index 00000000000..eb9d559580c --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/charts/rollout_operator/templates/serviceaccount.yaml @@ -0,0 +1,12 @@ +--- +# Source: mimir-distributed/charts/rollout_operator/templates/serviceaccount.yaml +apiVersion: v1 +kind: ServiceAccount +metadata: + name: test-enterprise-component-image-values-rollout-operator + labels: + helm.sh/chart: rollout-operator-0.22.0 + app.kubernetes.io/name: rollout-operator + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/version: "v0.22.0" + app.kubernetes.io/managed-by: Helm diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/admin-api/admin-api-dep.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/admin-api/admin-api-dep.yaml new file mode 100644 index 00000000000..109731e92d8 --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/admin-api/admin-api-dep.yaml @@ -0,0 +1,119 @@ +--- +# Source: mimir-distributed/templates/admin-api/admin-api-dep.yaml +apiVersion: apps/v1 +kind: Deployment +metadata: + annotations: + {} + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: admin-api + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + name: test-enterprise-component-image-values-mimir-admin-api + namespace: "citestns" +spec: + replicas: 1 + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: admin-api + strategy: + rollingUpdate: + maxSurge: 15% + maxUnavailable: 0 + type: RollingUpdate + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: admin-api + app.kubernetes.io/part-of: memberlist + annotations: + namespace: "citestns" + spec: + serviceAccountName: test-enterprise-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + containers: + - name: admin-api + image: test/admin-api:1-admin-api + imagePullPolicy: IfNotPresent + args: + - "-target=admin-api" + - "-config.expand-env=true" + - "-config.file=/etc/mimir/mimir.yaml" + volumeMounts: + - name: config + mountPath: /etc/mimir + - name: runtime-config + mountPath: /var/mimir + - name: license + mountPath: /license + - name: storage + mountPath: "/data" + - name: active-queries + mountPath: /active-query-tracker + ports: + - name: http-metrics + containerPort: 8080 + protocol: TCP + - name: grpc + containerPort: 9095 + protocol: TCP + - name: memberlist + containerPort: 7946 + protocol: TCP + livenessProbe: + null + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 45 + resources: + requests: + cpu: 10m + memory: 32Mi + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true + topologySpreadConstraints: + - maxSkew: 1 + topologyKey: kubernetes.io/hostname + whenUnsatisfiable: ScheduleAnyway + labelSelector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: admin-api + terminationGracePeriodSeconds: 60 + volumes: + - name: config + configMap: + name: test-enterprise-component-image-values-mimir-config + items: + - key: "mimir.yaml" + path: "mimir.yaml" + - name: runtime-config + configMap: + name: test-enterprise-component-image-values-mimir-runtime + - name: license + secret: + secretName: test-enterprise-component-image-values-mimir-license + - name: storage + emptyDir: {} + - name: active-queries + emptyDir: {} diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/admin-api/admin-api-pdb.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/admin-api/admin-api-pdb.yaml new file mode 100644 index 00000000000..40dc10a76b2 --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/admin-api/admin-api-pdb.yaml @@ -0,0 +1,19 @@ +--- +# Source: mimir-distributed/templates/admin-api/admin-api-pdb.yaml +apiVersion: policy/v1beta1 +kind: PodDisruptionBudget +metadata: + name: test-enterprise-component-image-values-mimir-admin-api + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: admin-api + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +spec: + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: admin-api + maxUnavailable: 1 diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/admin-api/admin-api-svc.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/admin-api/admin-api-svc.yaml new file mode 100644 index 00000000000..df4124e608e --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/admin-api/admin-api-svc.yaml @@ -0,0 +1,30 @@ +--- +# Source: mimir-distributed/templates/admin-api/admin-api-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-enterprise-component-image-values-mimir-admin-api + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: admin-api + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: admin-api diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-config.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-config.yaml new file mode 100644 index 00000000000..97f402115a6 --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-config.yaml @@ -0,0 +1,21 @@ +--- +# Source: mimir-distributed/templates/alertmanager/alertmanager-config.yaml +apiVersion: v1 +kind: ConfigMap +metadata: + name: test-enterprise-component-image-values-mimir-alertmanager-fallback-config + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: alertmanager + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +data: + alertmanager_fallback_config.yaml: | + receivers: + - name: default-receiver + route: + receiver: default-receiver diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-pdb.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-pdb.yaml new file mode 100644 index 00000000000..e434d33fdb5 --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-pdb.yaml @@ -0,0 +1,19 @@ +--- +# Source: mimir-distributed/templates/alertmanager/alertmanager-pdb.yaml +apiVersion: policy/v1beta1 +kind: PodDisruptionBudget +metadata: + name: test-enterprise-component-image-values-mimir-alertmanager + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: alertmanager + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +spec: + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: alertmanager + maxUnavailable: 1 diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-statefulset.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-statefulset.yaml new file mode 100644 index 00000000000..5d337ede35e --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-statefulset.yaml @@ -0,0 +1,139 @@ +--- +# Source: mimir-distributed/templates/alertmanager/alertmanager-statefulset.yaml +apiVersion: apps/v1 +kind: StatefulSet +metadata: + name: test-enterprise-component-image-values-mimir-alertmanager + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: alertmanager + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +spec: + replicas: 1 + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: alertmanager + updateStrategy: + type: RollingUpdate + serviceName: test-enterprise-component-image-values-mimir-alertmanager + volumeClaimTemplates: + - apiVersion: v1 + kind: PersistentVolumeClaim + metadata: + name: storage + spec: + accessModes: + - ReadWriteOnce + resources: + requests: + storage: "1Gi" + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: alertmanager + app.kubernetes.io/part-of: memberlist + annotations: + namespace: "citestns" + spec: + serviceAccountName: test-enterprise-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + topologySpreadConstraints: + - maxSkew: 1 + topologyKey: kubernetes.io/hostname + whenUnsatisfiable: ScheduleAnyway + labelSelector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: alertmanager + terminationGracePeriodSeconds: 900 + volumes: + - name: config + configMap: + name: test-enterprise-component-image-values-mimir-config + items: + - key: "mimir.yaml" + path: "mimir.yaml" + - name: license + secret: + secretName: test-enterprise-component-image-values-mimir-license + - name: runtime-config + configMap: + name: test-enterprise-component-image-values-mimir-runtime + - name: tmp + emptyDir: {} + - name: active-queries + emptyDir: {} + - name: alertmanager-fallback-config + configMap: + name: test-enterprise-component-image-values-mimir-alertmanager-fallback-config + containers: + - name: alertmanager + image: test/alertmanager:1-alertmanager + imagePullPolicy: IfNotPresent + args: + - "-target=alertmanager" + - "-config.expand-env=true" + - "-config.file=/etc/mimir/mimir.yaml" + # Prometheus HTTP client used to send alerts has a hard-coded idle + # timeout of 5 minutes, therefore the server timeout for Alertmanager + # needs to be higher to avoid connections being closed abruptly. + - "-server.http-idle-timeout=6m" + volumeMounts: + - name: config + mountPath: /etc/mimir + - name: license + mountPath: /license + - name: runtime-config + mountPath: /var/mimir + - name: storage + mountPath: "/data" + - name: alertmanager-fallback-config + mountPath: /configs/ + - name: tmp + mountPath: /tmp + - name: active-queries + mountPath: /active-query-tracker + ports: + - name: http-metrics + containerPort: 8080 + protocol: TCP + - name: grpc + containerPort: 9095 + protocol: TCP + - name: memberlist + containerPort: 7946 + protocol: TCP + livenessProbe: + null + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 45 + resources: + requests: + cpu: 10m + memory: 32Mi + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-svc-headless.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-svc-headless.yaml new file mode 100644 index 00000000000..009147fcd48 --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-svc-headless.yaml @@ -0,0 +1,36 @@ +--- +# Source: mimir-distributed/templates/alertmanager/alertmanager-svc-headless.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-enterprise-component-image-values-mimir-alertmanager-headless + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: alertmanager + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + prometheus.io/service-monitor: "false" + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + clusterIP: None + publishNotReadyAddresses: true + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + - port: 9094 + protocol: TCP + name: cluster + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: alertmanager diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-svc.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-svc.yaml new file mode 100644 index 00000000000..4a1f092f07c --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-svc.yaml @@ -0,0 +1,30 @@ +--- +# Source: mimir-distributed/templates/alertmanager/alertmanager-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-enterprise-component-image-values-mimir-alertmanager + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: alertmanager + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: alertmanager diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/compactor/compactor-pdb.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/compactor/compactor-pdb.yaml new file mode 100644 index 00000000000..11fe6c5fb6c --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/compactor/compactor-pdb.yaml @@ -0,0 +1,19 @@ +--- +# Source: mimir-distributed/templates/compactor/compactor-pdb.yaml +apiVersion: policy/v1beta1 +kind: PodDisruptionBudget +metadata: + name: test-enterprise-component-image-values-mimir-compactor + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: compactor + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +spec: + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: compactor + maxUnavailable: 1 diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/compactor/compactor-statefulset.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/compactor/compactor-statefulset.yaml new file mode 100644 index 00000000000..e2b5660fc4e --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/compactor/compactor-statefulset.yaml @@ -0,0 +1,127 @@ +--- +# Source: mimir-distributed/templates/compactor/compactor-statefulset.yaml +apiVersion: apps/v1 +kind: StatefulSet +metadata: + name: test-enterprise-component-image-values-mimir-compactor + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: compactor + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +spec: + podManagementPolicy: OrderedReady + replicas: 1 + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: compactor + updateStrategy: + type: RollingUpdate + serviceName: test-enterprise-component-image-values-mimir-compactor + volumeClaimTemplates: + - apiVersion: v1 + kind: PersistentVolumeClaim + metadata: + name: storage + spec: + accessModes: + - ReadWriteOnce + resources: + requests: + storage: "2Gi" + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: compactor + app.kubernetes.io/part-of: memberlist + annotations: + namespace: "citestns" + spec: + serviceAccountName: test-enterprise-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + topologySpreadConstraints: + - maxSkew: 1 + topologyKey: kubernetes.io/hostname + whenUnsatisfiable: ScheduleAnyway + labelSelector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: compactor + terminationGracePeriodSeconds: 900 + volumes: + - name: config + configMap: + name: test-enterprise-component-image-values-mimir-config + items: + - key: "mimir.yaml" + path: "mimir.yaml" + - name: license + secret: + secretName: test-enterprise-component-image-values-mimir-license + - name: runtime-config + configMap: + name: test-enterprise-component-image-values-mimir-runtime + - name: active-queries + emptyDir: {} + containers: + - name: compactor + image: test/compactor:1-compactor + imagePullPolicy: IfNotPresent + args: + - "-target=compactor" + - "-config.expand-env=true" + - "-config.file=/etc/mimir/mimir.yaml" + volumeMounts: + - name: config + mountPath: /etc/mimir + - name: license + mountPath: /license + - name: runtime-config + mountPath: /var/mimir + - name: storage + mountPath: "/data" + - name: active-queries + mountPath: /active-query-tracker + ports: + - name: http-metrics + containerPort: 8080 + protocol: TCP + - name: grpc + containerPort: 9095 + protocol: TCP + - name: memberlist + containerPort: 7946 + protocol: TCP + livenessProbe: + null + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 60 + resources: + requests: + cpu: 100m + memory: 512Mi + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/compactor/compactor-svc.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/compactor/compactor-svc.yaml new file mode 100644 index 00000000000..d8cbaff8b6f --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/compactor/compactor-svc.yaml @@ -0,0 +1,30 @@ +--- +# Source: mimir-distributed/templates/compactor/compactor-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-enterprise-component-image-values-mimir-compactor + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: compactor + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: compactor diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/distributor/distributor-dep.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/distributor/distributor-dep.yaml new file mode 100644 index 00000000000..cfaa75dea88 --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/distributor/distributor-dep.yaml @@ -0,0 +1,132 @@ +--- +# Source: mimir-distributed/templates/distributor/distributor-dep.yaml +apiVersion: apps/v1 +kind: Deployment +metadata: + name: test-enterprise-component-image-values-mimir-distributor + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: distributor + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +spec: + # If replicas is not number (when using values file it's float64, when using --set arg it's int64) and is false (i.e. null) don't set it + replicas: 1 + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: distributor + strategy: + rollingUpdate: + maxSurge: 15% + maxUnavailable: 0 + type: RollingUpdate + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: distributor + app.kubernetes.io/part-of: memberlist + annotations: + namespace: "citestns" + spec: + serviceAccountName: test-enterprise-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + containers: + - name: distributor + image: test/distributor:1-distributor + imagePullPolicy: IfNotPresent + args: + - "-target=distributor" + - "-config.expand-env=true" + - "-config.file=/etc/mimir/mimir.yaml" + # When write requests go through distributors via gRPC, we want gRPC clients to re-resolve the distributors DNS + # endpoint before the distributor process is terminated, in order to avoid any failures during graceful shutdown. + # To achieve it, we set a shutdown delay greater than the gRPC max connection age. + - "-server.grpc.keepalive.max-connection-age=60s" + - "-server.grpc.keepalive.max-connection-age-grace=5m" + - "-server.grpc.keepalive.max-connection-idle=1m" + - "-shutdown-delay=90s" + volumeMounts: + - name: config + mountPath: /etc/mimir + - name: license + mountPath: /license + - name: runtime-config + mountPath: /var/mimir + - name: storage + mountPath: "/data" + - name: active-queries + mountPath: /active-query-tracker + ports: + - name: http-metrics + containerPort: 8080 + protocol: TCP + - name: grpc + containerPort: 9095 + protocol: TCP + - name: memberlist + containerPort: 7946 + protocol: TCP + livenessProbe: + null + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 45 + resources: + requests: + cpu: 100m + memory: 512Mi + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true + env: + - name: "GOMAXPROCS" + value: "8" + - name: "JAEGER_REPORTER_MAX_QUEUE_SIZE" + value: "1000" + topologySpreadConstraints: + - maxSkew: 1 + topologyKey: kubernetes.io/hostname + whenUnsatisfiable: ScheduleAnyway + labelSelector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: distributor + terminationGracePeriodSeconds: 100 + volumes: + - name: config + configMap: + name: test-enterprise-component-image-values-mimir-config + items: + - key: "mimir.yaml" + path: "mimir.yaml" + - name: license + secret: + secretName: test-enterprise-component-image-values-mimir-license + - name: runtime-config + configMap: + name: test-enterprise-component-image-values-mimir-runtime + - name: storage + emptyDir: {} + - name: active-queries + emptyDir: {} diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/distributor/distributor-pdb.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/distributor/distributor-pdb.yaml new file mode 100644 index 00000000000..b8cdcbb162e --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/distributor/distributor-pdb.yaml @@ -0,0 +1,19 @@ +--- +# Source: mimir-distributed/templates/distributor/distributor-pdb.yaml +apiVersion: policy/v1beta1 +kind: PodDisruptionBudget +metadata: + name: test-enterprise-component-image-values-mimir-distributor + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: distributor + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +spec: + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: distributor + maxUnavailable: 1 diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/distributor/distributor-svc-headless.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/distributor/distributor-svc-headless.yaml new file mode 100644 index 00000000000..cb1a21c5f43 --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/distributor/distributor-svc-headless.yaml @@ -0,0 +1,32 @@ +--- +# Source: mimir-distributed/templates/distributor/distributor-svc-headless.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-enterprise-component-image-values-mimir-distributor-headless + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: distributor + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + prometheus.io/service-monitor: "false" + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + clusterIP: None + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: distributor diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/distributor/distributor-svc.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/distributor/distributor-svc.yaml new file mode 100644 index 00000000000..78a04e1366b --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/distributor/distributor-svc.yaml @@ -0,0 +1,30 @@ +--- +# Source: mimir-distributed/templates/distributor/distributor-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-enterprise-component-image-values-mimir-distributor + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: distributor + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: distributor diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/federation-frontend/federation-frontend-dep.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/federation-frontend/federation-frontend-dep.yaml new file mode 100644 index 00000000000..87b11e35d8d --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/federation-frontend/federation-frontend-dep.yaml @@ -0,0 +1,96 @@ +--- +# Source: mimir-distributed/templates/federation-frontend/federation-frontend-dep.yaml +apiVersion: apps/v1 +kind: Deployment +metadata: + name: test-enterprise-component-image-values-mimir-federation-frontend + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: federation-frontend + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +spec: + replicas: 2 + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: federation-frontend + strategy: + rollingUpdate: + maxSurge: 15% + maxUnavailable: 0 + type: RollingUpdate + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: federation-frontend + annotations: + spec: + serviceAccountName: test-enterprise-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + containers: + - name: federation-frontend + image: test/federation_frontend:1-federation-frontend + imagePullPolicy: IfNotPresent + args: + - "-target=federation-frontend" + - "-config.expand-env=true" + - "-config.file=/etc/mimir/mimir.yaml" + volumeMounts: + - name: config + mountPath: /etc/mimir + - name: license + mountPath: /license + - name: active-queries + mountPath: /active-query-tracker + ports: + - name: http-metrics + containerPort: 8080 + protocol: TCP + - name: grpc + containerPort: 9095 + protocol: TCP + livenessProbe: + null + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 45 + resources: + requests: + cpu: 100m + memory: 128Mi + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true + + terminationGracePeriodSeconds: 180 + volumes: + - name: config + configMap: + name: test-enterprise-component-image-values-mimir-config + items: + - key: "mimir.yaml" + path: "mimir.yaml" + - name: license + secret: + secretName: test-enterprise-component-image-values-mimir-license + - name: active-queries + emptyDir: {} diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/federation-frontend/federation-frontend-pdb.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/federation-frontend/federation-frontend-pdb.yaml new file mode 100644 index 00000000000..ac77b85949a --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/federation-frontend/federation-frontend-pdb.yaml @@ -0,0 +1,19 @@ +--- +# Source: mimir-distributed/templates/federation-frontend/federation-frontend-pdb.yaml +apiVersion: policy/v1beta1 +kind: PodDisruptionBudget +metadata: + name: test-enterprise-component-image-values-mimir-federation-frontend + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: federation-frontend + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +spec: + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: federation-frontend + maxUnavailable: 1 diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/federation-frontend/federation-frontend-svc.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/federation-frontend/federation-frontend-svc.yaml new file mode 100644 index 00000000000..7ddc1e09459 --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/federation-frontend/federation-frontend-svc.yaml @@ -0,0 +1,29 @@ +--- +# Source: mimir-distributed/templates/federation-frontend/federation-frontend-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-enterprise-component-image-values-mimir-federation-frontend + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: federation-frontend + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: federation-frontend diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/gateway/gateway-dep.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/gateway/gateway-dep.yaml new file mode 100644 index 00000000000..53bc4a7dd8b --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/gateway/gateway-dep.yaml @@ -0,0 +1,110 @@ +--- +# Source: mimir-distributed/templates/gateway/gateway-dep.yaml +apiVersion: apps/v1 +kind: Deployment +metadata: + annotations: + {} + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: gateway + app.kubernetes.io/managed-by: Helm + name: test-enterprise-component-image-values-mimir-gateway + namespace: "citestns" +spec: + replicas: 1 + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: gateway + strategy: + rollingUpdate: + maxSurge: 15% + maxUnavailable: 0 + type: RollingUpdate + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: gateway + annotations: + namespace: "citestns" + spec: + serviceAccountName: test-enterprise-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + containers: + - name: gateway + image: test/gateway:1-gateway + imagePullPolicy: IfNotPresent + args: + - "-target=gateway" + - "-config.expand-env=true" + - "-config.file=/etc/mimir/mimir.yaml" + volumeMounts: + - name: config + mountPath: /etc/mimir + - name: runtime-config + mountPath: /var/mimir + - name: license + mountPath: /license + - name: tmp + mountPath: /data + - name: active-queries + mountPath: /active-query-tracker + ports: + - name: http-metrics + containerPort: 8080 + protocol: TCP + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 15 + timeoutSeconds: 1 + resources: + {} + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true + topologySpreadConstraints: + - maxSkew: 1 + topologyKey: kubernetes.io/hostname + whenUnsatisfiable: ScheduleAnyway + labelSelector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: gateway + terminationGracePeriodSeconds: 30 + volumes: + - name: config + configMap: + name: test-enterprise-component-image-values-mimir-config + items: + - key: "mimir.yaml" + path: "mimir.yaml" + - name: runtime-config + configMap: + name: test-enterprise-component-image-values-mimir-runtime + - name: tmp + emptyDir: {} + - name: license + secret: + secretName: test-enterprise-component-image-values-mimir-license + - name: storage + emptyDir: {} + - name: active-queries + emptyDir: {} diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/gateway/gateway-pdb.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/gateway/gateway-pdb.yaml new file mode 100644 index 00000000000..a3ebb8924ce --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/gateway/gateway-pdb.yaml @@ -0,0 +1,19 @@ +--- +# Source: mimir-distributed/templates/gateway/gateway-pdb.yaml +apiVersion: policy/v1beta1 +kind: PodDisruptionBudget +metadata: + name: test-enterprise-component-image-values-mimir-gateway + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: gateway + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +spec: + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: gateway + maxUnavailable: 1 diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/gateway/gateway-svc.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/gateway/gateway-svc.yaml new file mode 100644 index 00000000000..100d5994d5e --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/gateway/gateway-svc.yaml @@ -0,0 +1,29 @@ +--- +# Source: mimir-distributed/templates/gateway/gateway-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-enterprise-component-image-values-mimir-gateway + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: gateway + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + ports: + - port: 80 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 8080 + protocol: TCP + name: legacy-http-metrics + targetPort: http-metrics + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: gateway diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/gossip-ring/gossip-ring-svc.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/gossip-ring/gossip-ring-svc.yaml new file mode 100644 index 00000000000..b4a4f458c10 --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/gossip-ring/gossip-ring-svc.yaml @@ -0,0 +1,26 @@ +--- +# Source: mimir-distributed/templates/gossip-ring/gossip-ring-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-enterprise-component-image-values-mimir-gossip-ring + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: gossip-ring + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +spec: + type: ClusterIP + clusterIP: None + ports: + - name: gossip-ring + port: 7946 + appProtocol: tcp + protocol: TCP + targetPort: 7946 + publishNotReadyAddresses: true + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/part-of: memberlist diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/ingester/ingester-pdb.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/ingester/ingester-pdb.yaml new file mode 100644 index 00000000000..d1a88d7818f --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/ingester/ingester-pdb.yaml @@ -0,0 +1,19 @@ +--- +# Source: mimir-distributed/templates/ingester/ingester-pdb.yaml +apiVersion: policy/v1beta1 +kind: PodDisruptionBudget +metadata: + name: test-enterprise-component-image-values-mimir-ingester + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: ingester + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +spec: + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: ingester + maxUnavailable: 1 diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/ingester/ingester-statefulset.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/ingester/ingester-statefulset.yaml new file mode 100644 index 00000000000..731536ce1e0 --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/ingester/ingester-statefulset.yaml @@ -0,0 +1,426 @@ +--- +# Source: mimir-distributed/templates/ingester/ingester-statefulset.yaml +apiVersion: apps/v1 +kind: StatefulSet +metadata: + name: test-enterprise-component-image-values-mimir-ingester-zone-a + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: ingester + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + name: "ingester-zone-a" + rollout-group: ingester + zone: zone-a + annotations: + rollout-max-unavailable: "50" + namespace: "citestns" +spec: + podManagementPolicy: Parallel + replicas: 1 + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: ingester + rollout-group: ingester + zone: zone-a + updateStrategy: + type: OnDelete + serviceName: test-enterprise-component-image-values-mimir-ingester-headless + volumeClaimTemplates: + - apiVersion: v1 + kind: PersistentVolumeClaim + metadata: + name: storage + spec: + accessModes: + - ReadWriteOnce + resources: + requests: + storage: "2Gi" + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: ingester + app.kubernetes.io/part-of: memberlist + name: "ingester-zone-a" + rollout-group: ingester + zone: zone-a + annotations: + namespace: "citestns" + spec: + serviceAccountName: test-enterprise-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + topologySpreadConstraints: + - maxSkew: 1 + topologyKey: kubernetes.io/hostname + whenUnsatisfiable: ScheduleAnyway + labelSelector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: ingester + terminationGracePeriodSeconds: 1200 + volumes: + - name: config + configMap: + name: test-enterprise-component-image-values-mimir-config + items: + - key: "mimir.yaml" + path: "mimir.yaml" + - name: license + secret: + secretName: test-enterprise-component-image-values-mimir-license + - name: runtime-config + configMap: + name: test-enterprise-component-image-values-mimir-runtime + - name: active-queries + emptyDir: {} + containers: + - name: ingester + image: test/ingester:1-ingester + imagePullPolicy: IfNotPresent + args: + - "-target=ingester" + - "-config.expand-env=true" + - "-config.file=/etc/mimir/mimir.yaml" + - "-ingester.ring.instance-availability-zone=zone-a" + volumeMounts: + - name: config + mountPath: /etc/mimir + - name: runtime-config + mountPath: /var/mimir + - name: storage + mountPath: "/data" + - name: license + mountPath: /license + - name: active-queries + mountPath: /active-query-tracker + ports: + - name: http-metrics + containerPort: 8080 + protocol: TCP + - name: grpc + containerPort: 9095 + protocol: TCP + - name: memberlist + containerPort: 7946 + protocol: TCP + livenessProbe: + null + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 60 + resources: + requests: + cpu: 100m + memory: 512Mi + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true + env: + + - name: "GOMAXPROCS" + value: "4" + - name: "JAEGER_REPORTER_MAX_QUEUE_SIZE" + value: "1000" +--- +# Source: mimir-distributed/templates/ingester/ingester-statefulset.yaml +apiVersion: apps/v1 +kind: StatefulSet +metadata: + name: test-enterprise-component-image-values-mimir-ingester-zone-b + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: ingester + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + name: "ingester-zone-b" + rollout-group: ingester + zone: zone-b + annotations: + rollout-max-unavailable: "50" + namespace: "citestns" +spec: + podManagementPolicy: Parallel + replicas: 1 + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: ingester + rollout-group: ingester + zone: zone-b + updateStrategy: + type: OnDelete + serviceName: test-enterprise-component-image-values-mimir-ingester-headless + volumeClaimTemplates: + - apiVersion: v1 + kind: PersistentVolumeClaim + metadata: + name: storage + spec: + accessModes: + - ReadWriteOnce + resources: + requests: + storage: "2Gi" + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: ingester + app.kubernetes.io/part-of: memberlist + name: "ingester-zone-b" + rollout-group: ingester + zone: zone-b + annotations: + namespace: "citestns" + spec: + serviceAccountName: test-enterprise-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + topologySpreadConstraints: + - maxSkew: 1 + topologyKey: kubernetes.io/hostname + whenUnsatisfiable: ScheduleAnyway + labelSelector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: ingester + terminationGracePeriodSeconds: 1200 + volumes: + - name: config + configMap: + name: test-enterprise-component-image-values-mimir-config + items: + - key: "mimir.yaml" + path: "mimir.yaml" + - name: license + secret: + secretName: test-enterprise-component-image-values-mimir-license + - name: runtime-config + configMap: + name: test-enterprise-component-image-values-mimir-runtime + - name: active-queries + emptyDir: {} + containers: + - name: ingester + image: test/ingester:1-ingester + imagePullPolicy: IfNotPresent + args: + - "-target=ingester" + - "-config.expand-env=true" + - "-config.file=/etc/mimir/mimir.yaml" + - "-ingester.ring.instance-availability-zone=zone-b" + volumeMounts: + - name: config + mountPath: /etc/mimir + - name: runtime-config + mountPath: /var/mimir + - name: storage + mountPath: "/data" + - name: license + mountPath: /license + - name: active-queries + mountPath: /active-query-tracker + ports: + - name: http-metrics + containerPort: 8080 + protocol: TCP + - name: grpc + containerPort: 9095 + protocol: TCP + - name: memberlist + containerPort: 7946 + protocol: TCP + livenessProbe: + null + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 60 + resources: + requests: + cpu: 100m + memory: 512Mi + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true + env: + + - name: "GOMAXPROCS" + value: "4" + - name: "JAEGER_REPORTER_MAX_QUEUE_SIZE" + value: "1000" +--- +# Source: mimir-distributed/templates/ingester/ingester-statefulset.yaml +apiVersion: apps/v1 +kind: StatefulSet +metadata: + name: test-enterprise-component-image-values-mimir-ingester-zone-c + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: ingester + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + name: "ingester-zone-c" + rollout-group: ingester + zone: zone-c + annotations: + rollout-max-unavailable: "50" + namespace: "citestns" +spec: + podManagementPolicy: Parallel + replicas: 1 + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: ingester + rollout-group: ingester + zone: zone-c + updateStrategy: + type: OnDelete + serviceName: test-enterprise-component-image-values-mimir-ingester-headless + volumeClaimTemplates: + - apiVersion: v1 + kind: PersistentVolumeClaim + metadata: + name: storage + spec: + accessModes: + - ReadWriteOnce + resources: + requests: + storage: "2Gi" + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: ingester + app.kubernetes.io/part-of: memberlist + name: "ingester-zone-c" + rollout-group: ingester + zone: zone-c + annotations: + namespace: "citestns" + spec: + serviceAccountName: test-enterprise-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + topologySpreadConstraints: + - maxSkew: 1 + topologyKey: kubernetes.io/hostname + whenUnsatisfiable: ScheduleAnyway + labelSelector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: ingester + terminationGracePeriodSeconds: 1200 + volumes: + - name: config + configMap: + name: test-enterprise-component-image-values-mimir-config + items: + - key: "mimir.yaml" + path: "mimir.yaml" + - name: license + secret: + secretName: test-enterprise-component-image-values-mimir-license + - name: runtime-config + configMap: + name: test-enterprise-component-image-values-mimir-runtime + - name: active-queries + emptyDir: {} + containers: + - name: ingester + image: test/ingester:1-ingester + imagePullPolicy: IfNotPresent + args: + - "-target=ingester" + - "-config.expand-env=true" + - "-config.file=/etc/mimir/mimir.yaml" + - "-ingester.ring.instance-availability-zone=zone-c" + volumeMounts: + - name: config + mountPath: /etc/mimir + - name: runtime-config + mountPath: /var/mimir + - name: storage + mountPath: "/data" + - name: license + mountPath: /license + - name: active-queries + mountPath: /active-query-tracker + ports: + - name: http-metrics + containerPort: 8080 + protocol: TCP + - name: grpc + containerPort: 9095 + protocol: TCP + - name: memberlist + containerPort: 7946 + protocol: TCP + livenessProbe: + null + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 60 + resources: + requests: + cpu: 100m + memory: 512Mi + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true + env: + + - name: "GOMAXPROCS" + value: "4" + - name: "JAEGER_REPORTER_MAX_QUEUE_SIZE" + value: "1000" diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/ingester/ingester-svc-headless.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/ingester/ingester-svc-headless.yaml new file mode 100644 index 00000000000..cbb8a66132a --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/ingester/ingester-svc-headless.yaml @@ -0,0 +1,32 @@ +--- +# Source: mimir-distributed/templates/ingester/ingester-svc-headless.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-enterprise-component-image-values-mimir-ingester-headless + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: ingester + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + prometheus.io/service-monitor: "false" + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + clusterIP: None + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: ingester diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/ingester/ingester-svc.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/ingester/ingester-svc.yaml new file mode 100644 index 00000000000..44649c7a1b8 --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/ingester/ingester-svc.yaml @@ -0,0 +1,105 @@ +--- +# Source: mimir-distributed/templates/ingester/ingester-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-enterprise-component-image-values-mimir-ingester-zone-a + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: ingester + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + name: "ingester-zone-a" + rollout-group: ingester + zone: zone-a + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: ingester + rollout-group: ingester + zone: zone-a +--- +# Source: mimir-distributed/templates/ingester/ingester-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-enterprise-component-image-values-mimir-ingester-zone-b + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: ingester + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + name: "ingester-zone-b" + rollout-group: ingester + zone: zone-b + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: ingester + rollout-group: ingester + zone: zone-b +--- +# Source: mimir-distributed/templates/ingester/ingester-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-enterprise-component-image-values-mimir-ingester-zone-c + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: ingester + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + name: "ingester-zone-c" + rollout-group: ingester + zone: zone-c + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: ingester + rollout-group: ingester + zone: zone-c diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/license-secret.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/license-secret.yaml new file mode 100644 index 00000000000..b9ac6dec040 --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/license-secret.yaml @@ -0,0 +1,13 @@ +--- +# Source: mimir-distributed/templates/license-secret.yaml +apiVersion: v1 +kind: Secret +metadata: + name: test-enterprise-component-image-values-mimir-license + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +data: + license.jwt: Tk9UQVZBTElETElDRU5TRQ== diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/mimir-config.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/mimir-config.yaml new file mode 100644 index 00000000000..c6f1c320694 --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/mimir-config.yaml @@ -0,0 +1,137 @@ +--- +# Source: mimir-distributed/templates/mimir-config.yaml +apiVersion: v1 +kind: ConfigMap +metadata: + name: test-enterprise-component-image-values-mimir-config + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +data: + mimir.yaml: | + + activity_tracker: + filepath: /active-query-tracker/activity.log + admin_api: + leader_election: + enabled: true + ring: + kvstore: + store: memberlist + admin_client: + storage: null + alertmanager: + data_dir: /data + enable_api: true + external_url: /alertmanager + fallback_config_file: /configs/alertmanager_fallback_config.yaml + auth: + admin: + pass_access_policy_name: true + pass_token_name: true + type: enterprise + blocks_storage: + backend: s3 + bucket_store: + sync_dir: /data/tsdb-sync + tsdb: + dir: /data/tsdb + head_compaction_interval: 15m + wal_replay_concurrency: 3 + cluster_name: test-enterprise-component-image-values + compactor: + compaction_interval: 30m + data_dir: /data + deletion_delay: 2h + first_level_compaction_wait_period: 25m + max_closing_blocks_concurrency: 2 + max_opening_blocks_concurrency: 4 + sharding_ring: + heartbeat_period: 1m + heartbeat_timeout: 4m + wait_stability_min_duration: 1m + symbols_flushers_concurrency: 4 + distributor: + ring: + heartbeat_period: 1m + heartbeat_timeout: 4m + frontend: + log_query_request_headers: X-Access-Policy-Name,X-Token-Name + parallelize_shardable_queries: true + scheduler_address: test-enterprise-component-image-values-mimir-query-scheduler-headless.citestns.svc:9095 + frontend_worker: + grpc_client_config: + max_send_msg_size: 419430400 + scheduler_address: test-enterprise-component-image-values-mimir-query-scheduler-headless.citestns.svc:9095 + gateway: + proxy: + admin_api: + url: http://test-enterprise-component-image-values-mimir-admin-api.citestns.svc:8080 + alertmanager: + url: http://test-enterprise-component-image-values-mimir-alertmanager-headless.citestns.svc:8080 + compactor: + url: http://test-enterprise-component-image-values-mimir-compactor.citestns.svc:8080 + default: + url: http://test-enterprise-component-image-values-mimir-admin-api.citestns.svc:8080 + distributor: + url: dns:///test-enterprise-component-image-values-mimir-distributor-headless.citestns.svc.cluster.local.:9095 + ingester: + url: http://test-enterprise-component-image-values-mimir-ingester-headless.citestns.svc:8080 + query_frontend: + url: http://test-enterprise-component-image-values-mimir-federation-frontend.citestns.svc:8080 + ruler: + url: http://test-enterprise-component-image-values-mimir-ruler.citestns.svc:8080 + store_gateway: + url: http://test-enterprise-component-image-values-mimir-store-gateway-headless.citestns.svc:8080 + ingester: + ring: + final_sleep: 0s + heartbeat_period: 2m + heartbeat_timeout: 10m + num_tokens: 512 + tokens_file_path: /data/tokens + unregister_on_shutdown: false + zone_awareness_enabled: true + ingester_client: + grpc_client_config: + max_recv_msg_size: 104857600 + max_send_msg_size: 104857600 + instrumentation: + distributor_client: + address: dns:///test-enterprise-component-image-values-mimir-distributor-headless.citestns.svc.cluster.local.:9095 + enabled: true + license: + path: /license/license.jwt + limits: + max_cache_freshness: 10m + max_query_parallelism: 240 + max_total_query_length: 12000h + memberlist: + abort_if_cluster_join_fails: false + compression_enabled: false + join_members: + - dns+test-enterprise-component-image-values-mimir-gossip-ring.citestns.svc.cluster.local.:7946 + querier: + max_concurrent: 16 + query_scheduler: + max_outstanding_requests_per_tenant: 800 + ruler: + alertmanager_url: dnssrvnoa+http://_http-metrics._tcp.test-enterprise-component-image-values-mimir-alertmanager-headless.citestns.svc.cluster.local./alertmanager + enable_api: true + rule_path: /data + runtime_config: + file: /var/mimir/runtime.yaml + store_gateway: + sharding_ring: + heartbeat_period: 1m + heartbeat_timeout: 4m + kvstore: + prefix: multi-zone/ + tokens_file_path: /data/tokens + unregister_on_shutdown: false + wait_stability_min_duration: 1m + zone_awareness_enabled: true + usage_stats: + installation_mode: helm diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/overrides-exporter/overrides-exporter-dep.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/overrides-exporter/overrides-exporter-dep.yaml new file mode 100644 index 00000000000..a8d1282f5ec --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/overrides-exporter/overrides-exporter-dep.yaml @@ -0,0 +1,109 @@ +--- +# Source: mimir-distributed/templates/overrides-exporter/overrides-exporter-dep.yaml +apiVersion: apps/v1 +kind: Deployment +metadata: + annotations: + {} + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: overrides-exporter + app.kubernetes.io/managed-by: Helm + name: test-enterprise-component-image-values-mimir-overrides-exporter + namespace: "citestns" +spec: + replicas: 1 + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: overrides-exporter + strategy: + rollingUpdate: + maxSurge: 15% + maxUnavailable: 0 + type: RollingUpdate + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: overrides-exporter + annotations: + namespace: "citestns" + spec: + serviceAccountName: test-enterprise-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + containers: + - name: overrides-exporter + image: test/overrides_exporter:1-overrides-exporter + imagePullPolicy: IfNotPresent + args: + - "-target=overrides-exporter" + - "-config.expand-env=true" + - "-config.file=/etc/mimir/mimir.yaml" + volumeMounts: + - name: config + mountPath: /etc/mimir + - name: license + mountPath: /license + - name: runtime-config + mountPath: /var/mimir + - name: storage + mountPath: "/data" + - name: active-queries + mountPath: /active-query-tracker + ports: + - name: http-metrics + containerPort: 8080 + protocol: TCP + - name: grpc + containerPort: 9095 + protocol: TCP + livenessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 45 + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 45 + resources: + requests: + cpu: 100m + memory: 128Mi + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true + + terminationGracePeriodSeconds: 30 + volumes: + - name: config + configMap: + name: test-enterprise-component-image-values-mimir-config + items: + - key: "mimir.yaml" + path: "mimir.yaml" + - name: license + secret: + secretName: test-enterprise-component-image-values-mimir-license + - name: runtime-config + configMap: + name: test-enterprise-component-image-values-mimir-runtime + - name: storage + emptyDir: {} + - name: active-queries + emptyDir: {} diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/overrides-exporter/overrides-exporter-pdb.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/overrides-exporter/overrides-exporter-pdb.yaml new file mode 100644 index 00000000000..eed973e61cc --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/overrides-exporter/overrides-exporter-pdb.yaml @@ -0,0 +1,19 @@ +--- +# Source: mimir-distributed/templates/overrides-exporter/overrides-exporter-pdb.yaml +apiVersion: policy/v1beta1 +kind: PodDisruptionBudget +metadata: + name: test-enterprise-component-image-values-mimir-overrides-exporter + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: overrides-exporter + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +spec: + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: overrides-exporter + maxUnavailable: 1 diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/overrides-exporter/overrides-exporter-svc.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/overrides-exporter/overrides-exporter-svc.yaml new file mode 100644 index 00000000000..c3280ec94cb --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/overrides-exporter/overrides-exporter-svc.yaml @@ -0,0 +1,29 @@ +--- +# Source: mimir-distributed/templates/overrides-exporter/overrides-exporter-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-enterprise-component-image-values-mimir-overrides-exporter + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: overrides-exporter + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: overrides-exporter diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/podsecuritypolicy.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/podsecuritypolicy.yaml new file mode 100644 index 00000000000..5b3b2bb67da --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/podsecuritypolicy.yaml @@ -0,0 +1,40 @@ +--- +# Source: mimir-distributed/templates/podsecuritypolicy.yaml +apiVersion: policy/v1beta1 +kind: PodSecurityPolicy +metadata: + name: test-enterprise-component-image-values-mimir + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/managed-by: Helm + annotations: + "seccomp.security.alpha.kubernetes.io/allowedProfileNames": runtime/default +spec: + privileged: false + allowPrivilegeEscalation: false + volumes: + - 'configMap' + - 'emptyDir' + - 'persistentVolumeClaim' + - 'secret' + hostNetwork: false + hostIPC: false + hostPID: false + runAsUser: + rule: MustRunAsNonRoot + seLinux: + rule: RunAsAny + supplementalGroups: + rule: MustRunAs + ranges: + - min: 1 + max: 65535 + fsGroup: + rule: MustRunAs + ranges: + - min: 1 + max: 65535 + readOnlyRootFilesystem: true + requiredDropCapabilities: + - ALL diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/querier/querier-dep.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/querier/querier-dep.yaml new file mode 100644 index 00000000000..bd67935962a --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/querier/querier-dep.yaml @@ -0,0 +1,124 @@ +--- +# Source: mimir-distributed/templates/querier/querier-dep.yaml +apiVersion: apps/v1 +kind: Deployment +metadata: + name: test-enterprise-component-image-values-mimir-querier + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: querier + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +spec: + # If replicas is not number (when using values file it's float64, when using --set arg it's int64) and is false (i.e. null) don't set it + replicas: 2 + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: querier + strategy: + rollingUpdate: + maxSurge: 15% + maxUnavailable: 0 + type: RollingUpdate + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: querier + app.kubernetes.io/part-of: memberlist + annotations: + spec: + serviceAccountName: test-enterprise-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + containers: + - name: querier + image: test/querier:1-querier + imagePullPolicy: IfNotPresent + args: + - "-target=querier" + - "-config.expand-env=true" + - "-config.file=/etc/mimir/mimir.yaml" + volumeMounts: + - name: config + mountPath: /etc/mimir + - name: license + mountPath: /license + - name: runtime-config + mountPath: /var/mimir + - name: storage + mountPath: "/data" + - name: active-queries + mountPath: /active-query-tracker + ports: + - name: http-metrics + containerPort: 8080 + protocol: TCP + - name: grpc + containerPort: 9095 + protocol: TCP + - name: memberlist + containerPort: 7946 + protocol: TCP + livenessProbe: + null + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 45 + resources: + requests: + cpu: 100m + memory: 128Mi + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true + env: + - name: "GOMAXPROCS" + value: "5" + - name: "JAEGER_REPORTER_MAX_QUEUE_SIZE" + value: "5000" + topologySpreadConstraints: + - maxSkew: 1 + topologyKey: kubernetes.io/hostname + whenUnsatisfiable: ScheduleAnyway + labelSelector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: querier + terminationGracePeriodSeconds: 180 + volumes: + - name: config + configMap: + name: test-enterprise-component-image-values-mimir-config + items: + - key: "mimir.yaml" + path: "mimir.yaml" + - name: license + secret: + secretName: test-enterprise-component-image-values-mimir-license + - name: runtime-config + configMap: + name: test-enterprise-component-image-values-mimir-runtime + - name: storage + emptyDir: {} + - name: active-queries + emptyDir: {} diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/querier/querier-pdb.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/querier/querier-pdb.yaml new file mode 100644 index 00000000000..1d9ef1d3ea1 --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/querier/querier-pdb.yaml @@ -0,0 +1,19 @@ +--- +# Source: mimir-distributed/templates/querier/querier-pdb.yaml +apiVersion: policy/v1beta1 +kind: PodDisruptionBudget +metadata: + name: test-enterprise-component-image-values-mimir-querier + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: querier + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +spec: + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: querier + maxUnavailable: 1 diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/querier/querier-svc.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/querier/querier-svc.yaml new file mode 100644 index 00000000000..2acc06a8c41 --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/querier/querier-svc.yaml @@ -0,0 +1,30 @@ +--- +# Source: mimir-distributed/templates/querier/querier-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-enterprise-component-image-values-mimir-querier + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: querier + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: querier diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/query-frontend/query-frontend-dep.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/query-frontend/query-frontend-dep.yaml new file mode 100644 index 00000000000..811184d1b6a --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/query-frontend/query-frontend-dep.yaml @@ -0,0 +1,121 @@ +--- +# Source: mimir-distributed/templates/query-frontend/query-frontend-dep.yaml +apiVersion: apps/v1 +kind: Deployment +metadata: + name: test-enterprise-component-image-values-mimir-query-frontend + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: query-frontend + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +spec: + # If replicas is not number (when using values file it's float64, when using --set arg it's int64) and is false (i.e. null) don't set it + replicas: 1 + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: query-frontend + strategy: + rollingUpdate: + maxSurge: 15% + maxUnavailable: 0 + type: RollingUpdate + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: query-frontend + annotations: + namespace: "citestns" + spec: + serviceAccountName: test-enterprise-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + containers: + - name: query-frontend + image: test/query_frontend:1-query-frontend + imagePullPolicy: IfNotPresent + args: + - "-target=query-frontend" + - "-config.expand-env=true" + - "-config.file=/etc/mimir/mimir.yaml" + # Reduce the likelihood of queries hitting terminated query-frontends. + - "-server.grpc.keepalive.max-connection-age=30s" + - "-shutdown-delay=90s" + volumeMounts: + - name: runtime-config + mountPath: /var/mimir + - name: license + mountPath: /license + - name: config + mountPath: /etc/mimir + - name: storage + mountPath: /data + - name: active-queries + mountPath: /active-query-tracker + ports: + - name: http-metrics + containerPort: 8080 + protocol: TCP + - name: grpc + containerPort: 9095 + protocol: TCP + livenessProbe: + null + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 45 + resources: + requests: + cpu: 100m + memory: 128Mi + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true + env: + - name: "JAEGER_REPORTER_MAX_QUEUE_SIZE" + value: "5000" + topologySpreadConstraints: + - maxSkew: 1 + topologyKey: kubernetes.io/hostname + whenUnsatisfiable: ScheduleAnyway + labelSelector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: query-frontend + terminationGracePeriodSeconds: 390 + volumes: + - name: config + configMap: + name: test-enterprise-component-image-values-mimir-config + items: + - key: "mimir.yaml" + path: "mimir.yaml" + - name: license + secret: + secretName: test-enterprise-component-image-values-mimir-license + - name: runtime-config + configMap: + name: test-enterprise-component-image-values-mimir-runtime + - name: storage + emptyDir: {} + - name: active-queries + emptyDir: {} diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/query-frontend/query-frontend-pdb.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/query-frontend/query-frontend-pdb.yaml new file mode 100644 index 00000000000..3cc10f1d032 --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/query-frontend/query-frontend-pdb.yaml @@ -0,0 +1,19 @@ +--- +# Source: mimir-distributed/templates/query-frontend/query-frontend-pdb.yaml +apiVersion: policy/v1beta1 +kind: PodDisruptionBudget +metadata: + name: test-enterprise-component-image-values-mimir-query-frontend + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: query-frontend + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +spec: + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: query-frontend + maxUnavailable: 1 diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/query-frontend/query-frontend-svc.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/query-frontend/query-frontend-svc.yaml new file mode 100644 index 00000000000..d9a20951cae --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/query-frontend/query-frontend-svc.yaml @@ -0,0 +1,29 @@ +--- +# Source: mimir-distributed/templates/query-frontend/query-frontend-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-enterprise-component-image-values-mimir-query-frontend + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: query-frontend + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: query-frontend diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/query-scheduler/query-scheduler-dep.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/query-scheduler/query-scheduler-dep.yaml new file mode 100644 index 00000000000..9d7487750c1 --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/query-scheduler/query-scheduler-dep.yaml @@ -0,0 +1,113 @@ +--- +# Source: mimir-distributed/templates/query-scheduler/query-scheduler-dep.yaml +apiVersion: apps/v1 +kind: Deployment +metadata: + name: test-enterprise-component-image-values-mimir-query-scheduler + namespace: "citestns" + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: query-scheduler + app.kubernetes.io/managed-by: Helm + annotations: + {} +spec: + replicas: 2 + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: query-scheduler + strategy: + rollingUpdate: + maxSurge: 1 + maxUnavailable: 0 + type: RollingUpdate + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: query-scheduler + annotations: + spec: + serviceAccountName: test-enterprise-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + containers: + - name: query-scheduler + image: test/query_scheduler:1-query-scheduler + imagePullPolicy: IfNotPresent + args: + - "-target=query-scheduler" + - "-config.expand-env=true" + - "-config.file=/etc/mimir/mimir.yaml" + volumeMounts: + - name: runtime-config + mountPath: /var/mimir + - name: license + mountPath: /license + - name: config + mountPath: /etc/mimir + - name: storage + mountPath: /data + - name: active-queries + mountPath: /active-query-tracker + ports: + - name: http-metrics + containerPort: 8080 + protocol: TCP + - name: grpc + containerPort: 9095 + protocol: TCP + livenessProbe: + null + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 45 + resources: + requests: + cpu: 100m + memory: 128Mi + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true + topologySpreadConstraints: + - maxSkew: 1 + topologyKey: kubernetes.io/hostname + whenUnsatisfiable: ScheduleAnyway + labelSelector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: query-scheduler + terminationGracePeriodSeconds: 180 + volumes: + - name: config + configMap: + name: test-enterprise-component-image-values-mimir-config + items: + - key: "mimir.yaml" + path: "mimir.yaml" + - name: license + secret: + secretName: test-enterprise-component-image-values-mimir-license + - name: runtime-config + configMap: + name: test-enterprise-component-image-values-mimir-runtime + - name: storage + emptyDir: {} + - name: active-queries + emptyDir: {} diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/query-scheduler/query-scheduler-pdb.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/query-scheduler/query-scheduler-pdb.yaml new file mode 100644 index 00000000000..2d136583d1d --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/query-scheduler/query-scheduler-pdb.yaml @@ -0,0 +1,19 @@ +--- +# Source: mimir-distributed/templates/query-scheduler/query-scheduler-pdb.yaml +apiVersion: policy/v1beta1 +kind: PodDisruptionBudget +metadata: + name: test-enterprise-component-image-values-mimir-query-scheduler + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: query-scheduler + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +spec: + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: query-scheduler + maxUnavailable: 1 diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/query-scheduler/query-scheduler-svc-headless.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/query-scheduler/query-scheduler-svc-headless.yaml new file mode 100644 index 00000000000..ea1f8ab06d8 --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/query-scheduler/query-scheduler-svc-headless.yaml @@ -0,0 +1,32 @@ +--- +# Source: mimir-distributed/templates/query-scheduler/query-scheduler-svc-headless.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-enterprise-component-image-values-mimir-query-scheduler-headless + namespace: "citestns" + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: query-scheduler + app.kubernetes.io/managed-by: Helm + prometheus.io/service-monitor: "false" + annotations: + {} +spec: + type: ClusterIP + clusterIP: None + publishNotReadyAddresses: true + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: query-scheduler diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/query-scheduler/query-scheduler-svc.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/query-scheduler/query-scheduler-svc.yaml new file mode 100644 index 00000000000..731b4ed0b60 --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/query-scheduler/query-scheduler-svc.yaml @@ -0,0 +1,29 @@ +--- +# Source: mimir-distributed/templates/query-scheduler/query-scheduler-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-enterprise-component-image-values-mimir-query-scheduler + namespace: "citestns" + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: query-scheduler + app.kubernetes.io/managed-by: Helm + annotations: + {} +spec: + type: ClusterIP + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: query-scheduler diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/role.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/role.yaml new file mode 100644 index 00000000000..ba845ed067f --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/role.yaml @@ -0,0 +1,16 @@ +--- +# Source: mimir-distributed/templates/role.yaml +apiVersion: rbac.authorization.k8s.io/v1 +kind: Role +metadata: + name: test-enterprise-component-image-values-mimir + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +rules: +- apiGroups: ['extensions'] + resources: ['podsecuritypolicies'] + verbs: ['use'] + resourceNames: [test-enterprise-component-image-values-mimir] diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/rolebinding.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/rolebinding.yaml new file mode 100644 index 00000000000..08f0b64559c --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/rolebinding.yaml @@ -0,0 +1,20 @@ +--- +# Source: mimir-distributed/templates/rolebinding.yaml +apiVersion: rbac.authorization.k8s.io/v1 +kind: RoleBinding +metadata: + name: test-enterprise-component-image-values-mimir + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: Role + name: test-enterprise-component-image-values-mimir +subjects: +- kind: ServiceAccount + name: test-enterprise-component-image-values-mimir +- kind: ServiceAccount + name: test-enterprise-component-image-values-mimir-distributed diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/ruler/ruler-dep.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/ruler/ruler-dep.yaml new file mode 100644 index 00000000000..dbd8e4c8ce6 --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/ruler/ruler-dep.yaml @@ -0,0 +1,123 @@ +--- +# Source: mimir-distributed/templates/ruler/ruler-dep.yaml +apiVersion: apps/v1 +kind: Deployment +metadata: + name: test-enterprise-component-image-values-mimir-ruler + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: ruler + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +spec: + replicas: 1 + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: ruler + strategy: + rollingUpdate: + maxSurge: 50% + maxUnavailable: 0 + type: RollingUpdate + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: ruler + app.kubernetes.io/part-of: memberlist + annotations: + namespace: "citestns" + spec: + serviceAccountName: test-enterprise-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + containers: + - name: ruler + image: test/ruler:1-ruler + imagePullPolicy: IfNotPresent + args: + - "-target=ruler" + - "-config.expand-env=true" + - "-config.file=/etc/mimir/mimir.yaml" + - "-distributor.remote-timeout=10s" + volumeMounts: + - name: config + mountPath: /etc/mimir + - name: license + mountPath: /license + - name: runtime-config + mountPath: /var/mimir + - name: storage + mountPath: "/data" + - name: active-queries + mountPath: /active-query-tracker + ports: + - name: http-metrics + containerPort: 8080 + protocol: TCP + - name: grpc + containerPort: 9095 + protocol: TCP + - name: memberlist + containerPort: 7946 + protocol: TCP + livenessProbe: + null + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 45 + resources: + requests: + cpu: 100m + memory: 128Mi + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true + env: + - name: "JAEGER_REPORTER_MAX_QUEUE_SIZE" + value: "1000" + topologySpreadConstraints: + - maxSkew: 1 + topologyKey: kubernetes.io/hostname + whenUnsatisfiable: ScheduleAnyway + labelSelector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: ruler + terminationGracePeriodSeconds: 600 + volumes: + - name: config + configMap: + name: test-enterprise-component-image-values-mimir-config + items: + - key: "mimir.yaml" + path: "mimir.yaml" + - name: license + secret: + secretName: test-enterprise-component-image-values-mimir-license + - name: runtime-config + configMap: + name: test-enterprise-component-image-values-mimir-runtime + - name: storage + emptyDir: {} + - name: active-queries + emptyDir: {} diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/ruler/ruler-pdb.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/ruler/ruler-pdb.yaml new file mode 100644 index 00000000000..e74a1f125dd --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/ruler/ruler-pdb.yaml @@ -0,0 +1,19 @@ +--- +# Source: mimir-distributed/templates/ruler/ruler-pdb.yaml +apiVersion: policy/v1beta1 +kind: PodDisruptionBudget +metadata: + name: test-enterprise-component-image-values-mimir-ruler + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: ruler + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +spec: + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: ruler + maxUnavailable: 1 diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/ruler/ruler-svc.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/ruler/ruler-svc.yaml new file mode 100644 index 00000000000..07d47fb5104 --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/ruler/ruler-svc.yaml @@ -0,0 +1,26 @@ +--- +# Source: mimir-distributed/templates/ruler/ruler-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-enterprise-component-image-values-mimir-ruler + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: ruler + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: ruler diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/runtime-configmap.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/runtime-configmap.yaml new file mode 100644 index 00000000000..c4f76d8639f --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/runtime-configmap.yaml @@ -0,0 +1,15 @@ +--- +# Source: mimir-distributed/templates/runtime-configmap.yaml +apiVersion: v1 +kind: ConfigMap +metadata: + name: test-enterprise-component-image-values-mimir-runtime + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +data: + runtime.yaml: | + + {} diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/serviceaccount.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/serviceaccount.yaml new file mode 100644 index 00000000000..4f6eb1c9e24 --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/serviceaccount.yaml @@ -0,0 +1,13 @@ +--- +# Source: mimir-distributed/templates/serviceaccount.yaml +apiVersion: v1 +kind: ServiceAccount +metadata: + name: test-enterprise-component-image-values-mimir + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/store-gateway/store-gateway-pdb.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/store-gateway/store-gateway-pdb.yaml new file mode 100644 index 00000000000..581eb019fe5 --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/store-gateway/store-gateway-pdb.yaml @@ -0,0 +1,19 @@ +--- +# Source: mimir-distributed/templates/store-gateway/store-gateway-pdb.yaml +apiVersion: policy/v1beta1 +kind: PodDisruptionBudget +metadata: + name: test-enterprise-component-image-values-mimir-store-gateway + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: store-gateway + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +spec: + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: store-gateway + maxUnavailable: 1 diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/store-gateway/store-gateway-statefulset.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/store-gateway/store-gateway-statefulset.yaml new file mode 100644 index 00000000000..6aff82b3737 --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/store-gateway/store-gateway-statefulset.yaml @@ -0,0 +1,429 @@ +--- +# Source: mimir-distributed/templates/store-gateway/store-gateway-statefulset.yaml +apiVersion: apps/v1 +kind: StatefulSet +metadata: + name: test-enterprise-component-image-values-mimir-store-gateway-zone-a + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: store-gateway + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + name: "store-gateway-zone-a" + rollout-group: store-gateway + zone: zone-a + annotations: + rollout-max-unavailable: "50" + namespace: "citestns" +spec: + podManagementPolicy: OrderedReady + replicas: 1 + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: store-gateway + rollout-group: store-gateway + zone: zone-a + updateStrategy: + type: OnDelete + serviceName: test-enterprise-component-image-values-mimir-store-gateway-headless + volumeClaimTemplates: + - apiVersion: v1 + kind: PersistentVolumeClaim + metadata: + name: storage + spec: + accessModes: + - ReadWriteOnce + resources: + requests: + storage: "2Gi" + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: store-gateway + app.kubernetes.io/part-of: memberlist + name: "store-gateway-zone-a" + rollout-group: store-gateway + zone: zone-a + annotations: + namespace: "citestns" + spec: + serviceAccountName: test-enterprise-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + topologySpreadConstraints: + - maxSkew: 1 + topologyKey: kubernetes.io/hostname + whenUnsatisfiable: ScheduleAnyway + labelSelector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: store-gateway + terminationGracePeriodSeconds: 120 + volumes: + - name: config + configMap: + name: test-enterprise-component-image-values-mimir-config + items: + - key: "mimir.yaml" + path: "mimir.yaml" + - name: license + secret: + secretName: test-enterprise-component-image-values-mimir-license + - name: runtime-config + configMap: + name: test-enterprise-component-image-values-mimir-runtime + - name: active-queries + emptyDir: {} + containers: + - name: store-gateway + image: test/store_gateway:1-store-gateway + imagePullPolicy: IfNotPresent + args: + - "-target=store-gateway" + - "-config.expand-env=true" + - "-config.file=/etc/mimir/mimir.yaml" + - "-store-gateway.sharding-ring.instance-availability-zone=zone-a" + volumeMounts: + - name: config + mountPath: /etc/mimir + - name: license + mountPath: /license + - name: runtime-config + mountPath: /var/mimir + - name: storage + mountPath: "/data" + - name: active-queries + mountPath: /active-query-tracker + ports: + - name: http-metrics + containerPort: 8080 + protocol: TCP + - name: grpc + containerPort: 9095 + protocol: TCP + - name: memberlist + containerPort: 7946 + protocol: TCP + livenessProbe: + null + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 60 + resources: + requests: + cpu: 100m + memory: 512Mi + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true + env: + - name: "GOMAXPROCS" + value: "5" + - name: "GOMEMLIMIT" + value: "536870912" + - name: "JAEGER_REPORTER_MAX_QUEUE_SIZE" + value: "1000" +--- +# Source: mimir-distributed/templates/store-gateway/store-gateway-statefulset.yaml +apiVersion: apps/v1 +kind: StatefulSet +metadata: + name: test-enterprise-component-image-values-mimir-store-gateway-zone-b + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: store-gateway + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + name: "store-gateway-zone-b" + rollout-group: store-gateway + zone: zone-b + annotations: + rollout-max-unavailable: "50" + namespace: "citestns" +spec: + podManagementPolicy: OrderedReady + replicas: 1 + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: store-gateway + rollout-group: store-gateway + zone: zone-b + updateStrategy: + type: OnDelete + serviceName: test-enterprise-component-image-values-mimir-store-gateway-headless + volumeClaimTemplates: + - apiVersion: v1 + kind: PersistentVolumeClaim + metadata: + name: storage + spec: + accessModes: + - ReadWriteOnce + resources: + requests: + storage: "2Gi" + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: store-gateway + app.kubernetes.io/part-of: memberlist + name: "store-gateway-zone-b" + rollout-group: store-gateway + zone: zone-b + annotations: + namespace: "citestns" + spec: + serviceAccountName: test-enterprise-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + topologySpreadConstraints: + - maxSkew: 1 + topologyKey: kubernetes.io/hostname + whenUnsatisfiable: ScheduleAnyway + labelSelector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: store-gateway + terminationGracePeriodSeconds: 120 + volumes: + - name: config + configMap: + name: test-enterprise-component-image-values-mimir-config + items: + - key: "mimir.yaml" + path: "mimir.yaml" + - name: license + secret: + secretName: test-enterprise-component-image-values-mimir-license + - name: runtime-config + configMap: + name: test-enterprise-component-image-values-mimir-runtime + - name: active-queries + emptyDir: {} + containers: + - name: store-gateway + image: test/store_gateway:1-store-gateway + imagePullPolicy: IfNotPresent + args: + - "-target=store-gateway" + - "-config.expand-env=true" + - "-config.file=/etc/mimir/mimir.yaml" + - "-store-gateway.sharding-ring.instance-availability-zone=zone-b" + volumeMounts: + - name: config + mountPath: /etc/mimir + - name: license + mountPath: /license + - name: runtime-config + mountPath: /var/mimir + - name: storage + mountPath: "/data" + - name: active-queries + mountPath: /active-query-tracker + ports: + - name: http-metrics + containerPort: 8080 + protocol: TCP + - name: grpc + containerPort: 9095 + protocol: TCP + - name: memberlist + containerPort: 7946 + protocol: TCP + livenessProbe: + null + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 60 + resources: + requests: + cpu: 100m + memory: 512Mi + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true + env: + - name: "GOMAXPROCS" + value: "5" + - name: "GOMEMLIMIT" + value: "536870912" + - name: "JAEGER_REPORTER_MAX_QUEUE_SIZE" + value: "1000" +--- +# Source: mimir-distributed/templates/store-gateway/store-gateway-statefulset.yaml +apiVersion: apps/v1 +kind: StatefulSet +metadata: + name: test-enterprise-component-image-values-mimir-store-gateway-zone-c + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: store-gateway + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + name: "store-gateway-zone-c" + rollout-group: store-gateway + zone: zone-c + annotations: + rollout-max-unavailable: "50" + namespace: "citestns" +spec: + podManagementPolicy: OrderedReady + replicas: 1 + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: store-gateway + rollout-group: store-gateway + zone: zone-c + updateStrategy: + type: OnDelete + serviceName: test-enterprise-component-image-values-mimir-store-gateway-headless + volumeClaimTemplates: + - apiVersion: v1 + kind: PersistentVolumeClaim + metadata: + name: storage + spec: + accessModes: + - ReadWriteOnce + resources: + requests: + storage: "2Gi" + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: store-gateway + app.kubernetes.io/part-of: memberlist + name: "store-gateway-zone-c" + rollout-group: store-gateway + zone: zone-c + annotations: + namespace: "citestns" + spec: + serviceAccountName: test-enterprise-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + topologySpreadConstraints: + - maxSkew: 1 + topologyKey: kubernetes.io/hostname + whenUnsatisfiable: ScheduleAnyway + labelSelector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: store-gateway + terminationGracePeriodSeconds: 120 + volumes: + - name: config + configMap: + name: test-enterprise-component-image-values-mimir-config + items: + - key: "mimir.yaml" + path: "mimir.yaml" + - name: license + secret: + secretName: test-enterprise-component-image-values-mimir-license + - name: runtime-config + configMap: + name: test-enterprise-component-image-values-mimir-runtime + - name: active-queries + emptyDir: {} + containers: + - name: store-gateway + image: test/store_gateway:1-store-gateway + imagePullPolicy: IfNotPresent + args: + - "-target=store-gateway" + - "-config.expand-env=true" + - "-config.file=/etc/mimir/mimir.yaml" + - "-store-gateway.sharding-ring.instance-availability-zone=zone-c" + volumeMounts: + - name: config + mountPath: /etc/mimir + - name: license + mountPath: /license + - name: runtime-config + mountPath: /var/mimir + - name: storage + mountPath: "/data" + - name: active-queries + mountPath: /active-query-tracker + ports: + - name: http-metrics + containerPort: 8080 + protocol: TCP + - name: grpc + containerPort: 9095 + protocol: TCP + - name: memberlist + containerPort: 7946 + protocol: TCP + livenessProbe: + null + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 60 + resources: + requests: + cpu: 100m + memory: 512Mi + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true + env: + - name: "GOMAXPROCS" + value: "5" + - name: "GOMEMLIMIT" + value: "536870912" + - name: "JAEGER_REPORTER_MAX_QUEUE_SIZE" + value: "1000" diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/store-gateway/store-gateway-svc-headless.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/store-gateway/store-gateway-svc-headless.yaml new file mode 100644 index 00000000000..34f19b05ba7 --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/store-gateway/store-gateway-svc-headless.yaml @@ -0,0 +1,32 @@ +--- +# Source: mimir-distributed/templates/store-gateway/store-gateway-svc-headless.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-enterprise-component-image-values-mimir-store-gateway-headless + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: store-gateway + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + prometheus.io/service-monitor: "false" + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + clusterIP: None + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: store-gateway diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/store-gateway/store-gateway-svc.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/store-gateway/store-gateway-svc.yaml new file mode 100644 index 00000000000..0c95e394276 --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/store-gateway/store-gateway-svc.yaml @@ -0,0 +1,105 @@ +--- +# Source: mimir-distributed/templates/store-gateway/store-gateway-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-enterprise-component-image-values-mimir-store-gateway-zone-a + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: store-gateway + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + name: "store-gateway-zone-a" + rollout-group: store-gateway + zone: zone-a + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: store-gateway + rollout-group: store-gateway + zone: zone-a +--- +# Source: mimir-distributed/templates/store-gateway/store-gateway-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-enterprise-component-image-values-mimir-store-gateway-zone-b + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: store-gateway + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + name: "store-gateway-zone-b" + rollout-group: store-gateway + zone: zone-b + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: store-gateway + rollout-group: store-gateway + zone: zone-b +--- +# Source: mimir-distributed/templates/store-gateway/store-gateway-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-enterprise-component-image-values-mimir-store-gateway-zone-c + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: store-gateway + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + name: "store-gateway-zone-c" + rollout-group: store-gateway + zone: zone-c + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: store-gateway + rollout-group: store-gateway + zone: zone-c diff --git a/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/tokengen/tokengen-job.yaml b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/tokengen/tokengen-job.yaml new file mode 100644 index 00000000000..d2c3f1d2f1b --- /dev/null +++ b/operations/helm/tests/test-enterprise-component-image-values-generated/mimir-distributed/templates/tokengen/tokengen-job.yaml @@ -0,0 +1,74 @@ +--- +# Source: mimir-distributed/templates/tokengen/tokengen-job.yaml +apiVersion: batch/v1 +kind: Job +metadata: + name: test-enterprise-component-image-values-mimir-tokengen + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/component: tokengen + app.kubernetes.io/managed-by: Helm + annotations: + "helm.sh/hook": post-install + namespace: "citestns" +spec: + backoffLimit: 6 + completions: 1 + parallelism: 1 + selector: + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-enterprise-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: tokengen + annotations: + namespace: "citestns" + spec: + serviceAccountName: test-enterprise-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + initContainers: + [] + containers: + - name: tokengen + imagePullPolicy: IfNotPresent + args: + - "-target=tokengen" + - "-config.expand-env=true" + - "-config.file=/etc/mimir/mimir.yaml" + volumeMounts: + - name: config + mountPath: /etc/mimir + - name: license + mountPath: /license + - name: active-queries + mountPath: /active-query-tracker + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true + restartPolicy: OnFailure + volumes: + - name: config + configMap: + name: test-enterprise-component-image-values-mimir-config + items: + - key: "mimir.yaml" + path: "mimir.yaml" + - name: license + secret: + secretName: test-enterprise-component-image-values-mimir-license + - name: storage + emptyDir: {} + - name: active-queries + emptyDir: {} diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/charts/rollout_operator/templates/deployment.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/charts/rollout_operator/templates/deployment.yaml new file mode 100644 index 00000000000..0b7d7a2b6bc --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/charts/rollout_operator/templates/deployment.yaml @@ -0,0 +1,65 @@ +--- +# Source: mimir-distributed/charts/rollout_operator/templates/deployment.yaml +apiVersion: apps/v1 +kind: Deployment +metadata: + name: test-oss-component-image-values-rollout-operator + labels: + helm.sh/chart: rollout-operator-0.22.0 + app.kubernetes.io/name: rollout-operator + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/version: "v0.22.0" + app.kubernetes.io/managed-by: Helm +spec: + replicas: 1 + minReadySeconds: 10 + selector: + matchLabels: + app.kubernetes.io/name: rollout-operator + app.kubernetes.io/instance: test-oss-component-image-values + strategy: + rollingUpdate: + maxSurge: 0 + maxUnavailable: 1 + template: + metadata: + labels: + app.kubernetes.io/name: rollout-operator + app.kubernetes.io/instance: test-oss-component-image-values + spec: + serviceAccountName: test-oss-component-image-values-rollout-operator + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + containers: + - name: rollout-operator + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true + image: "grafana/rollout-operator:v0.22.0" + imagePullPolicy: IfNotPresent + args: + - -kubernetes.namespace=citestns + ports: + - name: http-metrics + containerPort: 8001 + protocol: TCP + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 5 + timeoutSeconds: 1 + resources: + limits: + memory: 200Mi + requests: + cpu: 100m + memory: 100Mi diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/charts/rollout_operator/templates/role.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/charts/rollout_operator/templates/role.yaml new file mode 100644 index 00000000000..828ff453d14 --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/charts/rollout_operator/templates/role.yaml @@ -0,0 +1,36 @@ +--- +# Source: mimir-distributed/charts/rollout_operator/templates/role.yaml +apiVersion: rbac.authorization.k8s.io/v1 +kind: Role +metadata: + name: test-oss-component-image-values-rollout-operator + labels: + helm.sh/chart: rollout-operator-0.22.0 + app.kubernetes.io/name: rollout-operator + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/version: "v0.22.0" + app.kubernetes.io/managed-by: Helm +rules: +- apiGroups: + - "" + resources: + - pods + verbs: + - list + - get + - watch + - delete +- apiGroups: + - apps + resources: + - statefulsets + verbs: + - list + - get + - watch +- apiGroups: + - apps + resources: + - statefulsets/status + verbs: + - update diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/charts/rollout_operator/templates/rolebinding.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/charts/rollout_operator/templates/rolebinding.yaml new file mode 100644 index 00000000000..b3b3d797e8c --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/charts/rollout_operator/templates/rolebinding.yaml @@ -0,0 +1,19 @@ +--- +# Source: mimir-distributed/charts/rollout_operator/templates/rolebinding.yaml +apiVersion: rbac.authorization.k8s.io/v1 +kind: RoleBinding +metadata: + name: test-oss-component-image-values-rollout-operator + labels: + helm.sh/chart: rollout-operator-0.22.0 + app.kubernetes.io/name: rollout-operator + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/version: "v0.22.0" + app.kubernetes.io/managed-by: Helm +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: Role + name: test-oss-component-image-values-rollout-operator +subjects: +- kind: ServiceAccount + name: test-oss-component-image-values-rollout-operator diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/charts/rollout_operator/templates/serviceaccount.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/charts/rollout_operator/templates/serviceaccount.yaml new file mode 100644 index 00000000000..fe28e0fe9ec --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/charts/rollout_operator/templates/serviceaccount.yaml @@ -0,0 +1,12 @@ +--- +# Source: mimir-distributed/charts/rollout_operator/templates/serviceaccount.yaml +apiVersion: v1 +kind: ServiceAccount +metadata: + name: test-oss-component-image-values-rollout-operator + labels: + helm.sh/chart: rollout-operator-0.22.0 + app.kubernetes.io/name: rollout-operator + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/version: "v0.22.0" + app.kubernetes.io/managed-by: Helm diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-config.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-config.yaml new file mode 100644 index 00000000000..d2fe8cc0414 --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-config.yaml @@ -0,0 +1,21 @@ +--- +# Source: mimir-distributed/templates/alertmanager/alertmanager-config.yaml +apiVersion: v1 +kind: ConfigMap +metadata: + name: test-oss-component-image-values-mimir-alertmanager-fallback-config + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: alertmanager + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +data: + alertmanager_fallback_config.yaml: | + receivers: + - name: default-receiver + route: + receiver: default-receiver diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-pdb.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-pdb.yaml new file mode 100644 index 00000000000..bbdd875e461 --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-pdb.yaml @@ -0,0 +1,19 @@ +--- +# Source: mimir-distributed/templates/alertmanager/alertmanager-pdb.yaml +apiVersion: policy/v1beta1 +kind: PodDisruptionBudget +metadata: + name: test-oss-component-image-values-mimir-alertmanager + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: alertmanager + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +spec: + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: alertmanager + maxUnavailable: 1 diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-statefulset.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-statefulset.yaml new file mode 100644 index 00000000000..e920243061c --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-statefulset.yaml @@ -0,0 +1,134 @@ +--- +# Source: mimir-distributed/templates/alertmanager/alertmanager-statefulset.yaml +apiVersion: apps/v1 +kind: StatefulSet +metadata: + name: test-oss-component-image-values-mimir-alertmanager + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: alertmanager + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +spec: + replicas: 1 + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: alertmanager + updateStrategy: + type: RollingUpdate + serviceName: test-oss-component-image-values-mimir-alertmanager + volumeClaimTemplates: + - apiVersion: v1 + kind: PersistentVolumeClaim + metadata: + name: storage + spec: + accessModes: + - ReadWriteOnce + resources: + requests: + storage: "1Gi" + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: alertmanager + app.kubernetes.io/part-of: memberlist + annotations: + namespace: "citestns" + spec: + serviceAccountName: test-oss-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + topologySpreadConstraints: + - maxSkew: 1 + topologyKey: kubernetes.io/hostname + whenUnsatisfiable: ScheduleAnyway + labelSelector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: alertmanager + terminationGracePeriodSeconds: 900 + volumes: + - name: config + configMap: + name: test-oss-component-image-values-mimir-config + items: + - key: "mimir.yaml" + path: "mimir.yaml" + - name: runtime-config + configMap: + name: test-oss-component-image-values-mimir-runtime + - name: tmp + emptyDir: {} + - name: active-queries + emptyDir: {} + - name: alertmanager-fallback-config + configMap: + name: test-oss-component-image-values-mimir-alertmanager-fallback-config + containers: + - name: alertmanager + image: test/alertmanager:1-alertmanager + imagePullPolicy: IfNotPresent + args: + - "-target=alertmanager" + - "-config.expand-env=true" + - "-config.file=/etc/mimir/mimir.yaml" + # Prometheus HTTP client used to send alerts has a hard-coded idle + # timeout of 5 minutes, therefore the server timeout for Alertmanager + # needs to be higher to avoid connections being closed abruptly. + - "-server.http-idle-timeout=6m" + volumeMounts: + - name: config + mountPath: /etc/mimir + - name: runtime-config + mountPath: /var/mimir + - name: storage + mountPath: "/data" + - name: alertmanager-fallback-config + mountPath: /configs/ + - name: tmp + mountPath: /tmp + - name: active-queries + mountPath: /active-query-tracker + ports: + - name: http-metrics + containerPort: 8080 + protocol: TCP + - name: grpc + containerPort: 9095 + protocol: TCP + - name: memberlist + containerPort: 7946 + protocol: TCP + livenessProbe: + null + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 45 + resources: + requests: + cpu: 10m + memory: 32Mi + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-svc-headless.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-svc-headless.yaml new file mode 100644 index 00000000000..7ffd5da64f2 --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-svc-headless.yaml @@ -0,0 +1,36 @@ +--- +# Source: mimir-distributed/templates/alertmanager/alertmanager-svc-headless.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-oss-component-image-values-mimir-alertmanager-headless + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: alertmanager + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + prometheus.io/service-monitor: "false" + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + clusterIP: None + publishNotReadyAddresses: true + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + - port: 9094 + protocol: TCP + name: cluster + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: alertmanager diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-svc.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-svc.yaml new file mode 100644 index 00000000000..92934396128 --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/alertmanager/alertmanager-svc.yaml @@ -0,0 +1,30 @@ +--- +# Source: mimir-distributed/templates/alertmanager/alertmanager-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-oss-component-image-values-mimir-alertmanager + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: alertmanager + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: alertmanager diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/compactor/compactor-pdb.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/compactor/compactor-pdb.yaml new file mode 100644 index 00000000000..74021686812 --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/compactor/compactor-pdb.yaml @@ -0,0 +1,19 @@ +--- +# Source: mimir-distributed/templates/compactor/compactor-pdb.yaml +apiVersion: policy/v1beta1 +kind: PodDisruptionBudget +metadata: + name: test-oss-component-image-values-mimir-compactor + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: compactor + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +spec: + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: compactor + maxUnavailable: 1 diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/compactor/compactor-statefulset.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/compactor/compactor-statefulset.yaml new file mode 100644 index 00000000000..bfc4cb9b3b6 --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/compactor/compactor-statefulset.yaml @@ -0,0 +1,122 @@ +--- +# Source: mimir-distributed/templates/compactor/compactor-statefulset.yaml +apiVersion: apps/v1 +kind: StatefulSet +metadata: + name: test-oss-component-image-values-mimir-compactor + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: compactor + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +spec: + podManagementPolicy: OrderedReady + replicas: 1 + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: compactor + updateStrategy: + type: RollingUpdate + serviceName: test-oss-component-image-values-mimir-compactor + volumeClaimTemplates: + - apiVersion: v1 + kind: PersistentVolumeClaim + metadata: + name: storage + spec: + accessModes: + - ReadWriteOnce + resources: + requests: + storage: "2Gi" + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: compactor + app.kubernetes.io/part-of: memberlist + annotations: + namespace: "citestns" + spec: + serviceAccountName: test-oss-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + topologySpreadConstraints: + - maxSkew: 1 + topologyKey: kubernetes.io/hostname + whenUnsatisfiable: ScheduleAnyway + labelSelector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: compactor + terminationGracePeriodSeconds: 900 + volumes: + - name: config + configMap: + name: test-oss-component-image-values-mimir-config + items: + - key: "mimir.yaml" + path: "mimir.yaml" + - name: runtime-config + configMap: + name: test-oss-component-image-values-mimir-runtime + - name: active-queries + emptyDir: {} + containers: + - name: compactor + image: test/compactor:1-compactor + imagePullPolicy: IfNotPresent + args: + - "-target=compactor" + - "-config.expand-env=true" + - "-config.file=/etc/mimir/mimir.yaml" + volumeMounts: + - name: config + mountPath: /etc/mimir + - name: runtime-config + mountPath: /var/mimir + - name: storage + mountPath: "/data" + - name: active-queries + mountPath: /active-query-tracker + ports: + - name: http-metrics + containerPort: 8080 + protocol: TCP + - name: grpc + containerPort: 9095 + protocol: TCP + - name: memberlist + containerPort: 7946 + protocol: TCP + livenessProbe: + null + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 60 + resources: + requests: + cpu: 100m + memory: 512Mi + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/compactor/compactor-svc.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/compactor/compactor-svc.yaml new file mode 100644 index 00000000000..7ba6f5e5f6c --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/compactor/compactor-svc.yaml @@ -0,0 +1,30 @@ +--- +# Source: mimir-distributed/templates/compactor/compactor-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-oss-component-image-values-mimir-compactor + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: compactor + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: compactor diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/distributor/distributor-dep.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/distributor/distributor-dep.yaml new file mode 100644 index 00000000000..f80729797e1 --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/distributor/distributor-dep.yaml @@ -0,0 +1,127 @@ +--- +# Source: mimir-distributed/templates/distributor/distributor-dep.yaml +apiVersion: apps/v1 +kind: Deployment +metadata: + name: test-oss-component-image-values-mimir-distributor + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: distributor + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +spec: + # If replicas is not number (when using values file it's float64, when using --set arg it's int64) and is false (i.e. null) don't set it + replicas: 1 + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: distributor + strategy: + rollingUpdate: + maxSurge: 15% + maxUnavailable: 0 + type: RollingUpdate + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: distributor + app.kubernetes.io/part-of: memberlist + annotations: + namespace: "citestns" + spec: + serviceAccountName: test-oss-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + containers: + - name: distributor + image: test/distributor:1-distributor + imagePullPolicy: IfNotPresent + args: + - "-target=distributor" + - "-config.expand-env=true" + - "-config.file=/etc/mimir/mimir.yaml" + # When write requests go through distributors via gRPC, we want gRPC clients to re-resolve the distributors DNS + # endpoint before the distributor process is terminated, in order to avoid any failures during graceful shutdown. + # To achieve it, we set a shutdown delay greater than the gRPC max connection age. + - "-server.grpc.keepalive.max-connection-age=60s" + - "-server.grpc.keepalive.max-connection-age-grace=5m" + - "-server.grpc.keepalive.max-connection-idle=1m" + - "-shutdown-delay=90s" + volumeMounts: + - name: config + mountPath: /etc/mimir + - name: runtime-config + mountPath: /var/mimir + - name: storage + mountPath: "/data" + - name: active-queries + mountPath: /active-query-tracker + ports: + - name: http-metrics + containerPort: 8080 + protocol: TCP + - name: grpc + containerPort: 9095 + protocol: TCP + - name: memberlist + containerPort: 7946 + protocol: TCP + livenessProbe: + null + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 45 + resources: + requests: + cpu: 100m + memory: 512Mi + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true + env: + - name: "GOMAXPROCS" + value: "8" + - name: "JAEGER_REPORTER_MAX_QUEUE_SIZE" + value: "1000" + topologySpreadConstraints: + - maxSkew: 1 + topologyKey: kubernetes.io/hostname + whenUnsatisfiable: ScheduleAnyway + labelSelector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: distributor + terminationGracePeriodSeconds: 100 + volumes: + - name: config + configMap: + name: test-oss-component-image-values-mimir-config + items: + - key: "mimir.yaml" + path: "mimir.yaml" + - name: runtime-config + configMap: + name: test-oss-component-image-values-mimir-runtime + - name: storage + emptyDir: {} + - name: active-queries + emptyDir: {} diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/distributor/distributor-pdb.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/distributor/distributor-pdb.yaml new file mode 100644 index 00000000000..1f90b3e896a --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/distributor/distributor-pdb.yaml @@ -0,0 +1,19 @@ +--- +# Source: mimir-distributed/templates/distributor/distributor-pdb.yaml +apiVersion: policy/v1beta1 +kind: PodDisruptionBudget +metadata: + name: test-oss-component-image-values-mimir-distributor + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: distributor + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +spec: + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: distributor + maxUnavailable: 1 diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/distributor/distributor-svc-headless.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/distributor/distributor-svc-headless.yaml new file mode 100644 index 00000000000..426fa189f4d --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/distributor/distributor-svc-headless.yaml @@ -0,0 +1,32 @@ +--- +# Source: mimir-distributed/templates/distributor/distributor-svc-headless.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-oss-component-image-values-mimir-distributor-headless + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: distributor + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + prometheus.io/service-monitor: "false" + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + clusterIP: None + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: distributor diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/distributor/distributor-svc.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/distributor/distributor-svc.yaml new file mode 100644 index 00000000000..6301fc0ee2c --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/distributor/distributor-svc.yaml @@ -0,0 +1,30 @@ +--- +# Source: mimir-distributed/templates/distributor/distributor-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-oss-component-image-values-mimir-distributor + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: distributor + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: distributor diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/gossip-ring/gossip-ring-svc.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/gossip-ring/gossip-ring-svc.yaml new file mode 100644 index 00000000000..dc6b36b3d05 --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/gossip-ring/gossip-ring-svc.yaml @@ -0,0 +1,26 @@ +--- +# Source: mimir-distributed/templates/gossip-ring/gossip-ring-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-oss-component-image-values-mimir-gossip-ring + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: gossip-ring + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +spec: + type: ClusterIP + clusterIP: None + ports: + - name: gossip-ring + port: 7946 + appProtocol: tcp + protocol: TCP + targetPort: 7946 + publishNotReadyAddresses: true + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/part-of: memberlist diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/ingester/ingester-pdb.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/ingester/ingester-pdb.yaml new file mode 100644 index 00000000000..b289c35d00b --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/ingester/ingester-pdb.yaml @@ -0,0 +1,19 @@ +--- +# Source: mimir-distributed/templates/ingester/ingester-pdb.yaml +apiVersion: policy/v1beta1 +kind: PodDisruptionBudget +metadata: + name: test-oss-component-image-values-mimir-ingester + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: ingester + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +spec: + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: ingester + maxUnavailable: 1 diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/ingester/ingester-statefulset.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/ingester/ingester-statefulset.yaml new file mode 100644 index 00000000000..480fddeb714 --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/ingester/ingester-statefulset.yaml @@ -0,0 +1,411 @@ +--- +# Source: mimir-distributed/templates/ingester/ingester-statefulset.yaml +apiVersion: apps/v1 +kind: StatefulSet +metadata: + name: test-oss-component-image-values-mimir-ingester-zone-a + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: ingester + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + name: "ingester-zone-a" + rollout-group: ingester + zone: zone-a + annotations: + rollout-max-unavailable: "50" + namespace: "citestns" +spec: + podManagementPolicy: Parallel + replicas: 1 + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: ingester + rollout-group: ingester + zone: zone-a + updateStrategy: + type: OnDelete + serviceName: test-oss-component-image-values-mimir-ingester-headless + volumeClaimTemplates: + - apiVersion: v1 + kind: PersistentVolumeClaim + metadata: + name: storage + spec: + accessModes: + - ReadWriteOnce + resources: + requests: + storage: "2Gi" + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: ingester + app.kubernetes.io/part-of: memberlist + name: "ingester-zone-a" + rollout-group: ingester + zone: zone-a + annotations: + namespace: "citestns" + spec: + serviceAccountName: test-oss-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + topologySpreadConstraints: + - maxSkew: 1 + topologyKey: kubernetes.io/hostname + whenUnsatisfiable: ScheduleAnyway + labelSelector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: ingester + terminationGracePeriodSeconds: 1200 + volumes: + - name: config + configMap: + name: test-oss-component-image-values-mimir-config + items: + - key: "mimir.yaml" + path: "mimir.yaml" + - name: runtime-config + configMap: + name: test-oss-component-image-values-mimir-runtime + - name: active-queries + emptyDir: {} + containers: + - name: ingester + image: test/ingester:1-ingester + imagePullPolicy: IfNotPresent + args: + - "-target=ingester" + - "-config.expand-env=true" + - "-config.file=/etc/mimir/mimir.yaml" + - "-ingester.ring.instance-availability-zone=zone-a" + volumeMounts: + - name: config + mountPath: /etc/mimir + - name: runtime-config + mountPath: /var/mimir + - name: storage + mountPath: "/data" + - name: active-queries + mountPath: /active-query-tracker + ports: + - name: http-metrics + containerPort: 8080 + protocol: TCP + - name: grpc + containerPort: 9095 + protocol: TCP + - name: memberlist + containerPort: 7946 + protocol: TCP + livenessProbe: + null + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 60 + resources: + requests: + cpu: 100m + memory: 512Mi + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true + env: + + - name: "GOMAXPROCS" + value: "4" + - name: "JAEGER_REPORTER_MAX_QUEUE_SIZE" + value: "1000" +--- +# Source: mimir-distributed/templates/ingester/ingester-statefulset.yaml +apiVersion: apps/v1 +kind: StatefulSet +metadata: + name: test-oss-component-image-values-mimir-ingester-zone-b + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: ingester + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + name: "ingester-zone-b" + rollout-group: ingester + zone: zone-b + annotations: + rollout-max-unavailable: "50" + namespace: "citestns" +spec: + podManagementPolicy: Parallel + replicas: 1 + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: ingester + rollout-group: ingester + zone: zone-b + updateStrategy: + type: OnDelete + serviceName: test-oss-component-image-values-mimir-ingester-headless + volumeClaimTemplates: + - apiVersion: v1 + kind: PersistentVolumeClaim + metadata: + name: storage + spec: + accessModes: + - ReadWriteOnce + resources: + requests: + storage: "2Gi" + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: ingester + app.kubernetes.io/part-of: memberlist + name: "ingester-zone-b" + rollout-group: ingester + zone: zone-b + annotations: + namespace: "citestns" + spec: + serviceAccountName: test-oss-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + topologySpreadConstraints: + - maxSkew: 1 + topologyKey: kubernetes.io/hostname + whenUnsatisfiable: ScheduleAnyway + labelSelector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: ingester + terminationGracePeriodSeconds: 1200 + volumes: + - name: config + configMap: + name: test-oss-component-image-values-mimir-config + items: + - key: "mimir.yaml" + path: "mimir.yaml" + - name: runtime-config + configMap: + name: test-oss-component-image-values-mimir-runtime + - name: active-queries + emptyDir: {} + containers: + - name: ingester + image: test/ingester:1-ingester + imagePullPolicy: IfNotPresent + args: + - "-target=ingester" + - "-config.expand-env=true" + - "-config.file=/etc/mimir/mimir.yaml" + - "-ingester.ring.instance-availability-zone=zone-b" + volumeMounts: + - name: config + mountPath: /etc/mimir + - name: runtime-config + mountPath: /var/mimir + - name: storage + mountPath: "/data" + - name: active-queries + mountPath: /active-query-tracker + ports: + - name: http-metrics + containerPort: 8080 + protocol: TCP + - name: grpc + containerPort: 9095 + protocol: TCP + - name: memberlist + containerPort: 7946 + protocol: TCP + livenessProbe: + null + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 60 + resources: + requests: + cpu: 100m + memory: 512Mi + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true + env: + + - name: "GOMAXPROCS" + value: "4" + - name: "JAEGER_REPORTER_MAX_QUEUE_SIZE" + value: "1000" +--- +# Source: mimir-distributed/templates/ingester/ingester-statefulset.yaml +apiVersion: apps/v1 +kind: StatefulSet +metadata: + name: test-oss-component-image-values-mimir-ingester-zone-c + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: ingester + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + name: "ingester-zone-c" + rollout-group: ingester + zone: zone-c + annotations: + rollout-max-unavailable: "50" + namespace: "citestns" +spec: + podManagementPolicy: Parallel + replicas: 1 + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: ingester + rollout-group: ingester + zone: zone-c + updateStrategy: + type: OnDelete + serviceName: test-oss-component-image-values-mimir-ingester-headless + volumeClaimTemplates: + - apiVersion: v1 + kind: PersistentVolumeClaim + metadata: + name: storage + spec: + accessModes: + - ReadWriteOnce + resources: + requests: + storage: "2Gi" + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: ingester + app.kubernetes.io/part-of: memberlist + name: "ingester-zone-c" + rollout-group: ingester + zone: zone-c + annotations: + namespace: "citestns" + spec: + serviceAccountName: test-oss-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + topologySpreadConstraints: + - maxSkew: 1 + topologyKey: kubernetes.io/hostname + whenUnsatisfiable: ScheduleAnyway + labelSelector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: ingester + terminationGracePeriodSeconds: 1200 + volumes: + - name: config + configMap: + name: test-oss-component-image-values-mimir-config + items: + - key: "mimir.yaml" + path: "mimir.yaml" + - name: runtime-config + configMap: + name: test-oss-component-image-values-mimir-runtime + - name: active-queries + emptyDir: {} + containers: + - name: ingester + image: test/ingester:1-ingester + imagePullPolicy: IfNotPresent + args: + - "-target=ingester" + - "-config.expand-env=true" + - "-config.file=/etc/mimir/mimir.yaml" + - "-ingester.ring.instance-availability-zone=zone-c" + volumeMounts: + - name: config + mountPath: /etc/mimir + - name: runtime-config + mountPath: /var/mimir + - name: storage + mountPath: "/data" + - name: active-queries + mountPath: /active-query-tracker + ports: + - name: http-metrics + containerPort: 8080 + protocol: TCP + - name: grpc + containerPort: 9095 + protocol: TCP + - name: memberlist + containerPort: 7946 + protocol: TCP + livenessProbe: + null + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 60 + resources: + requests: + cpu: 100m + memory: 512Mi + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true + env: + + - name: "GOMAXPROCS" + value: "4" + - name: "JAEGER_REPORTER_MAX_QUEUE_SIZE" + value: "1000" diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/ingester/ingester-svc-headless.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/ingester/ingester-svc-headless.yaml new file mode 100644 index 00000000000..e61a54bdaf5 --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/ingester/ingester-svc-headless.yaml @@ -0,0 +1,32 @@ +--- +# Source: mimir-distributed/templates/ingester/ingester-svc-headless.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-oss-component-image-values-mimir-ingester-headless + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: ingester + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + prometheus.io/service-monitor: "false" + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + clusterIP: None + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: ingester diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/ingester/ingester-svc.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/ingester/ingester-svc.yaml new file mode 100644 index 00000000000..83926e19197 --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/ingester/ingester-svc.yaml @@ -0,0 +1,105 @@ +--- +# Source: mimir-distributed/templates/ingester/ingester-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-oss-component-image-values-mimir-ingester-zone-a + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: ingester + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + name: "ingester-zone-a" + rollout-group: ingester + zone: zone-a + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: ingester + rollout-group: ingester + zone: zone-a +--- +# Source: mimir-distributed/templates/ingester/ingester-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-oss-component-image-values-mimir-ingester-zone-b + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: ingester + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + name: "ingester-zone-b" + rollout-group: ingester + zone: zone-b + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: ingester + rollout-group: ingester + zone: zone-b +--- +# Source: mimir-distributed/templates/ingester/ingester-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-oss-component-image-values-mimir-ingester-zone-c + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: ingester + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + name: "ingester-zone-c" + rollout-group: ingester + zone: zone-c + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: ingester + rollout-group: ingester + zone: zone-c diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/mimir-config.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/mimir-config.yaml new file mode 100644 index 00000000000..d7ae12eb1e4 --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/mimir-config.yaml @@ -0,0 +1,96 @@ +--- +# Source: mimir-distributed/templates/mimir-config.yaml +apiVersion: v1 +kind: ConfigMap +metadata: + name: test-oss-component-image-values-mimir-config + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +data: + mimir.yaml: | + + activity_tracker: + filepath: /active-query-tracker/activity.log + alertmanager: + data_dir: /data + enable_api: true + external_url: /alertmanager + fallback_config_file: /configs/alertmanager_fallback_config.yaml + blocks_storage: + backend: s3 + bucket_store: + sync_dir: /data/tsdb-sync + tsdb: + dir: /data/tsdb + head_compaction_interval: 15m + wal_replay_concurrency: 3 + compactor: + compaction_interval: 30m + data_dir: /data + deletion_delay: 2h + first_level_compaction_wait_period: 25m + max_closing_blocks_concurrency: 2 + max_opening_blocks_concurrency: 4 + sharding_ring: + heartbeat_period: 1m + heartbeat_timeout: 4m + wait_stability_min_duration: 1m + symbols_flushers_concurrency: 4 + distributor: + ring: + heartbeat_period: 1m + heartbeat_timeout: 4m + frontend: + parallelize_shardable_queries: true + scheduler_address: test-oss-component-image-values-mimir-query-scheduler-headless.citestns.svc:9095 + frontend_worker: + grpc_client_config: + max_send_msg_size: 419430400 + scheduler_address: test-oss-component-image-values-mimir-query-scheduler-headless.citestns.svc:9095 + ingester: + ring: + final_sleep: 0s + heartbeat_period: 2m + heartbeat_timeout: 10m + num_tokens: 512 + tokens_file_path: /data/tokens + unregister_on_shutdown: false + zone_awareness_enabled: true + ingester_client: + grpc_client_config: + max_recv_msg_size: 104857600 + max_send_msg_size: 104857600 + limits: + max_cache_freshness: 10m + max_query_parallelism: 240 + max_total_query_length: 12000h + memberlist: + abort_if_cluster_join_fails: false + compression_enabled: false + join_members: + - dns+test-oss-component-image-values-mimir-gossip-ring.citestns.svc.cluster.local.:7946 + querier: + max_concurrent: 16 + query_scheduler: + max_outstanding_requests_per_tenant: 800 + ruler: + alertmanager_url: dnssrvnoa+http://_http-metrics._tcp.test-oss-component-image-values-mimir-alertmanager-headless.citestns.svc.cluster.local./alertmanager + enable_api: true + rule_path: /data + runtime_config: + file: /var/mimir/runtime.yaml + store_gateway: + sharding_ring: + heartbeat_period: 1m + heartbeat_timeout: 4m + kvstore: + prefix: multi-zone/ + tokens_file_path: /data/tokens + unregister_on_shutdown: false + wait_stability_min_duration: 1m + zone_awareness_enabled: true + usage_stats: + installation_mode: helm diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/nginx/nginx-configmap.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/nginx/nginx-configmap.yaml new file mode 100644 index 00000000000..583c7ccf2ff --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/nginx/nginx-configmap.yaml @@ -0,0 +1,138 @@ +--- +# Source: mimir-distributed/templates/nginx/nginx-configmap.yaml +apiVersion: v1 +kind: ConfigMap +metadata: + name: test-oss-component-image-values-mimir-nginx + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: nginx + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +data: + nginx.conf: | + worker_processes 5; ## Default: 1 + error_log /dev/stderr error; + pid /tmp/nginx.pid; + worker_rlimit_nofile 8192; + + events { + worker_connections 4096; ## Default: 1024 + } + + http { + client_body_temp_path /tmp/client_temp; + proxy_temp_path /tmp/proxy_temp_path; + fastcgi_temp_path /tmp/fastcgi_temp; + uwsgi_temp_path /tmp/uwsgi_temp; + scgi_temp_path /tmp/scgi_temp; + + default_type application/octet-stream; + log_format main '$remote_addr - $remote_user [$time_local] $status ' + '"$request" $body_bytes_sent "$http_referer" ' + '"$http_user_agent" "$http_x_forwarded_for"'; + access_log /dev/stderr main; + + sendfile on; + tcp_nopush on; + proxy_http_version 1.1; + resolver kube-dns.kube-system.svc.cluster.local.; + + # Ensure that X-Scope-OrgID is always present, default to the no_auth_tenant for backwards compatibility when multi-tenancy was turned off. + map $http_x_scope_orgid $ensured_x_scope_orgid { + default $http_x_scope_orgid; + "" "anonymous"; + } + + map $http_x_scope_orgid $has_multiple_orgid_headers { + default 0; + "~^.+,.+$" 1; + } + + proxy_read_timeout 300; + server { + listen 8080; + listen [::]:8080; + + if ($has_multiple_orgid_headers = 1) { + return 400 'Sending multiple X-Scope-OrgID headers is not allowed. Use a single header with | as separator instead.'; + } + + location = / { + return 200 'OK'; + auth_basic off; + } + + proxy_set_header X-Scope-OrgID $ensured_x_scope_orgid; + + # Distributor endpoints + location /distributor { + set $distributor test-oss-component-image-values-mimir-distributor-headless.citestns.svc.cluster.local.; + proxy_pass http://$distributor:8080$request_uri; + } + location = /api/v1/push { + set $distributor test-oss-component-image-values-mimir-distributor-headless.citestns.svc.cluster.local.; + proxy_pass http://$distributor:8080$request_uri; + } + location /otlp/v1/metrics { + set $distributor test-oss-component-image-values-mimir-distributor-headless.citestns.svc.cluster.local.; + proxy_pass http://$distributor:8080$request_uri; + } + + # Alertmanager endpoints + location /alertmanager { + set $alertmanager test-oss-component-image-values-mimir-alertmanager-headless.citestns.svc.cluster.local.; + proxy_pass http://$alertmanager:8080$request_uri; + } + location = /multitenant_alertmanager/status { + set $alertmanager test-oss-component-image-values-mimir-alertmanager-headless.citestns.svc.cluster.local.; + proxy_pass http://$alertmanager:8080$request_uri; + } + location = /multitenant_alertmanager/configs { + set $alertmanager test-oss-component-image-values-mimir-alertmanager-headless.citestns.svc.cluster.local.; + proxy_pass http://$alertmanager:8080$request_uri; + } + location = /api/v1/alerts { + set $alertmanager test-oss-component-image-values-mimir-alertmanager-headless.citestns.svc.cluster.local.; + proxy_pass http://$alertmanager:8080$request_uri; + } + + # Ruler endpoints + location /prometheus/config/v1/rules { + set $ruler test-oss-component-image-values-mimir-ruler.citestns.svc.cluster.local.; + proxy_pass http://$ruler:8080$request_uri; + } + location /prometheus/api/v1/rules { + set $ruler test-oss-component-image-values-mimir-ruler.citestns.svc.cluster.local.; + proxy_pass http://$ruler:8080$request_uri; + } + + location /prometheus/api/v1/alerts { + set $ruler test-oss-component-image-values-mimir-ruler.citestns.svc.cluster.local.; + proxy_pass http://$ruler:8080$request_uri; + } + location = /ruler/ring { + set $ruler test-oss-component-image-values-mimir-ruler.citestns.svc.cluster.local.; + proxy_pass http://$ruler:8080$request_uri; + } + + # Rest of /prometheus goes to the query frontend + location /prometheus { + set $query_frontend test-oss-component-image-values-mimir-query-frontend.citestns.svc.cluster.local.; + proxy_pass http://$query_frontend:8080$request_uri; + } + + # Buildinfo endpoint can go to any component + location = /api/v1/status/buildinfo { + set $query_frontend test-oss-component-image-values-mimir-query-frontend.citestns.svc.cluster.local.; + proxy_pass http://$query_frontend:8080$request_uri; + } + + # Compactor endpoint for uploading blocks + location /api/v1/upload/block/ { + set $compactor test-oss-component-image-values-mimir-compactor.citestns.svc.cluster.local.; + proxy_pass http://$compactor:8080$request_uri; + } + } + } diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/nginx/nginx-dep.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/nginx/nginx-dep.yaml new file mode 100644 index 00000000000..ad188dbb376 --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/nginx/nginx-dep.yaml @@ -0,0 +1,92 @@ +--- +# Source: mimir-distributed/templates/nginx/nginx-dep.yaml +apiVersion: apps/v1 +kind: Deployment +metadata: + name: test-oss-component-image-values-mimir-nginx + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: nginx + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +spec: + replicas: 1 + strategy: + rollingUpdate: + maxSurge: 15% + maxUnavailable: 0 + type: RollingUpdate + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: nginx + template: + metadata: + annotations: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: nginx + namespace: "citestns" + spec: + serviceAccountName: test-oss-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + terminationGracePeriodSeconds: 30 + containers: + - name: nginx + image: docker.io/nginxinc/nginx-unprivileged:1.27-alpine + imagePullPolicy: IfNotPresent + ports: + - name: http-metric + containerPort: 8080 + protocol: TCP + readinessProbe: + httpGet: + path: / + port: http-metric + initialDelaySeconds: 15 + timeoutSeconds: 1 + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true + volumeMounts: + - name: config + mountPath: /etc/nginx/nginx.conf + subPath: nginx.conf + - name: tmp + mountPath: /tmp + - name: docker-entrypoint-d-override + mountPath: /docker-entrypoint.d + resources: + {} + topologySpreadConstraints: + - maxSkew: 1 + topologyKey: kubernetes.io/hostname + whenUnsatisfiable: ScheduleAnyway + labelSelector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: nginx + volumes: + - name: config + configMap: + name: test-oss-component-image-values-mimir-nginx + - name: tmp + emptyDir: {} + - name: docker-entrypoint-d-override + emptyDir: {} diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/nginx/nginx-pdb.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/nginx/nginx-pdb.yaml new file mode 100644 index 00000000000..3f27848fd81 --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/nginx/nginx-pdb.yaml @@ -0,0 +1,19 @@ +--- +# Source: mimir-distributed/templates/nginx/nginx-pdb.yaml +apiVersion: policy/v1beta1 +kind: PodDisruptionBudget +metadata: + name: test-oss-component-image-values-mimir-nginx + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: nginx + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +spec: + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: nginx + maxUnavailable: 1 diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/nginx/nginx-svc.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/nginx/nginx-svc.yaml new file mode 100644 index 00000000000..f3ec2dc1124 --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/nginx/nginx-svc.yaml @@ -0,0 +1,25 @@ +--- +# Source: mimir-distributed/templates/nginx/nginx-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-oss-component-image-values-mimir-nginx + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: nginx + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + ports: + - name: http-metric + port: 80 + targetPort: http-metric + protocol: TCP + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: nginx diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/overrides-exporter/overrides-exporter-dep.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/overrides-exporter/overrides-exporter-dep.yaml new file mode 100644 index 00000000000..5b5b33fd284 --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/overrides-exporter/overrides-exporter-dep.yaml @@ -0,0 +1,104 @@ +--- +# Source: mimir-distributed/templates/overrides-exporter/overrides-exporter-dep.yaml +apiVersion: apps/v1 +kind: Deployment +metadata: + annotations: + {} + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: overrides-exporter + app.kubernetes.io/managed-by: Helm + name: test-oss-component-image-values-mimir-overrides-exporter + namespace: "citestns" +spec: + replicas: 1 + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: overrides-exporter + strategy: + rollingUpdate: + maxSurge: 15% + maxUnavailable: 0 + type: RollingUpdate + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: overrides-exporter + annotations: + namespace: "citestns" + spec: + serviceAccountName: test-oss-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + containers: + - name: overrides-exporter + image: test/overrides_exporter:1-overrides-exporter + imagePullPolicy: IfNotPresent + args: + - "-target=overrides-exporter" + - "-config.expand-env=true" + - "-config.file=/etc/mimir/mimir.yaml" + volumeMounts: + - name: config + mountPath: /etc/mimir + - name: runtime-config + mountPath: /var/mimir + - name: storage + mountPath: "/data" + - name: active-queries + mountPath: /active-query-tracker + ports: + - name: http-metrics + containerPort: 8080 + protocol: TCP + - name: grpc + containerPort: 9095 + protocol: TCP + livenessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 45 + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 45 + resources: + requests: + cpu: 100m + memory: 128Mi + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true + + terminationGracePeriodSeconds: 30 + volumes: + - name: config + configMap: + name: test-oss-component-image-values-mimir-config + items: + - key: "mimir.yaml" + path: "mimir.yaml" + - name: runtime-config + configMap: + name: test-oss-component-image-values-mimir-runtime + - name: storage + emptyDir: {} + - name: active-queries + emptyDir: {} diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/overrides-exporter/overrides-exporter-pdb.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/overrides-exporter/overrides-exporter-pdb.yaml new file mode 100644 index 00000000000..328e8896470 --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/overrides-exporter/overrides-exporter-pdb.yaml @@ -0,0 +1,19 @@ +--- +# Source: mimir-distributed/templates/overrides-exporter/overrides-exporter-pdb.yaml +apiVersion: policy/v1beta1 +kind: PodDisruptionBudget +metadata: + name: test-oss-component-image-values-mimir-overrides-exporter + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: overrides-exporter + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +spec: + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: overrides-exporter + maxUnavailable: 1 diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/overrides-exporter/overrides-exporter-svc.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/overrides-exporter/overrides-exporter-svc.yaml new file mode 100644 index 00000000000..825a07ebc80 --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/overrides-exporter/overrides-exporter-svc.yaml @@ -0,0 +1,29 @@ +--- +# Source: mimir-distributed/templates/overrides-exporter/overrides-exporter-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-oss-component-image-values-mimir-overrides-exporter + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: overrides-exporter + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: overrides-exporter diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/podsecuritypolicy.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/podsecuritypolicy.yaml new file mode 100644 index 00000000000..95e21da7c3c --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/podsecuritypolicy.yaml @@ -0,0 +1,40 @@ +--- +# Source: mimir-distributed/templates/podsecuritypolicy.yaml +apiVersion: policy/v1beta1 +kind: PodSecurityPolicy +metadata: + name: test-oss-component-image-values-mimir + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/managed-by: Helm + annotations: + "seccomp.security.alpha.kubernetes.io/allowedProfileNames": runtime/default +spec: + privileged: false + allowPrivilegeEscalation: false + volumes: + - 'configMap' + - 'emptyDir' + - 'persistentVolumeClaim' + - 'secret' + hostNetwork: false + hostIPC: false + hostPID: false + runAsUser: + rule: MustRunAsNonRoot + seLinux: + rule: RunAsAny + supplementalGroups: + rule: MustRunAs + ranges: + - min: 1 + max: 65535 + fsGroup: + rule: MustRunAs + ranges: + - min: 1 + max: 65535 + readOnlyRootFilesystem: true + requiredDropCapabilities: + - ALL diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/querier/querier-dep.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/querier/querier-dep.yaml new file mode 100644 index 00000000000..5bd3b44a4bc --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/querier/querier-dep.yaml @@ -0,0 +1,119 @@ +--- +# Source: mimir-distributed/templates/querier/querier-dep.yaml +apiVersion: apps/v1 +kind: Deployment +metadata: + name: test-oss-component-image-values-mimir-querier + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: querier + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +spec: + # If replicas is not number (when using values file it's float64, when using --set arg it's int64) and is false (i.e. null) don't set it + replicas: 2 + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: querier + strategy: + rollingUpdate: + maxSurge: 15% + maxUnavailable: 0 + type: RollingUpdate + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: querier + app.kubernetes.io/part-of: memberlist + annotations: + spec: + serviceAccountName: test-oss-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + containers: + - name: querier + image: test/querier:1-querier + imagePullPolicy: IfNotPresent + args: + - "-target=querier" + - "-config.expand-env=true" + - "-config.file=/etc/mimir/mimir.yaml" + volumeMounts: + - name: config + mountPath: /etc/mimir + - name: runtime-config + mountPath: /var/mimir + - name: storage + mountPath: "/data" + - name: active-queries + mountPath: /active-query-tracker + ports: + - name: http-metrics + containerPort: 8080 + protocol: TCP + - name: grpc + containerPort: 9095 + protocol: TCP + - name: memberlist + containerPort: 7946 + protocol: TCP + livenessProbe: + null + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 45 + resources: + requests: + cpu: 100m + memory: 128Mi + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true + env: + - name: "GOMAXPROCS" + value: "5" + - name: "JAEGER_REPORTER_MAX_QUEUE_SIZE" + value: "5000" + topologySpreadConstraints: + - maxSkew: 1 + topologyKey: kubernetes.io/hostname + whenUnsatisfiable: ScheduleAnyway + labelSelector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: querier + terminationGracePeriodSeconds: 180 + volumes: + - name: config + configMap: + name: test-oss-component-image-values-mimir-config + items: + - key: "mimir.yaml" + path: "mimir.yaml" + - name: runtime-config + configMap: + name: test-oss-component-image-values-mimir-runtime + - name: storage + emptyDir: {} + - name: active-queries + emptyDir: {} diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/querier/querier-pdb.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/querier/querier-pdb.yaml new file mode 100644 index 00000000000..881686d988f --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/querier/querier-pdb.yaml @@ -0,0 +1,19 @@ +--- +# Source: mimir-distributed/templates/querier/querier-pdb.yaml +apiVersion: policy/v1beta1 +kind: PodDisruptionBudget +metadata: + name: test-oss-component-image-values-mimir-querier + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: querier + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +spec: + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: querier + maxUnavailable: 1 diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/querier/querier-svc.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/querier/querier-svc.yaml new file mode 100644 index 00000000000..77ef468eb14 --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/querier/querier-svc.yaml @@ -0,0 +1,30 @@ +--- +# Source: mimir-distributed/templates/querier/querier-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-oss-component-image-values-mimir-querier + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: querier + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: querier diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/query-frontend/query-frontend-dep.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/query-frontend/query-frontend-dep.yaml new file mode 100644 index 00000000000..93ca5581f5f --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/query-frontend/query-frontend-dep.yaml @@ -0,0 +1,116 @@ +--- +# Source: mimir-distributed/templates/query-frontend/query-frontend-dep.yaml +apiVersion: apps/v1 +kind: Deployment +metadata: + name: test-oss-component-image-values-mimir-query-frontend + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: query-frontend + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +spec: + # If replicas is not number (when using values file it's float64, when using --set arg it's int64) and is false (i.e. null) don't set it + replicas: 1 + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: query-frontend + strategy: + rollingUpdate: + maxSurge: 15% + maxUnavailable: 0 + type: RollingUpdate + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: query-frontend + annotations: + namespace: "citestns" + spec: + serviceAccountName: test-oss-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + containers: + - name: query-frontend + image: test/query_frontend:1-query-frontend + imagePullPolicy: IfNotPresent + args: + - "-target=query-frontend" + - "-config.expand-env=true" + - "-config.file=/etc/mimir/mimir.yaml" + # Reduce the likelihood of queries hitting terminated query-frontends. + - "-server.grpc.keepalive.max-connection-age=30s" + - "-shutdown-delay=90s" + volumeMounts: + - name: runtime-config + mountPath: /var/mimir + - name: config + mountPath: /etc/mimir + - name: storage + mountPath: /data + - name: active-queries + mountPath: /active-query-tracker + ports: + - name: http-metrics + containerPort: 8080 + protocol: TCP + - name: grpc + containerPort: 9095 + protocol: TCP + livenessProbe: + null + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 45 + resources: + requests: + cpu: 100m + memory: 128Mi + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true + env: + - name: "JAEGER_REPORTER_MAX_QUEUE_SIZE" + value: "5000" + topologySpreadConstraints: + - maxSkew: 1 + topologyKey: kubernetes.io/hostname + whenUnsatisfiable: ScheduleAnyway + labelSelector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: query-frontend + terminationGracePeriodSeconds: 390 + volumes: + - name: config + configMap: + name: test-oss-component-image-values-mimir-config + items: + - key: "mimir.yaml" + path: "mimir.yaml" + - name: runtime-config + configMap: + name: test-oss-component-image-values-mimir-runtime + - name: storage + emptyDir: {} + - name: active-queries + emptyDir: {} diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/query-frontend/query-frontend-pdb.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/query-frontend/query-frontend-pdb.yaml new file mode 100644 index 00000000000..8a5ec3ba994 --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/query-frontend/query-frontend-pdb.yaml @@ -0,0 +1,19 @@ +--- +# Source: mimir-distributed/templates/query-frontend/query-frontend-pdb.yaml +apiVersion: policy/v1beta1 +kind: PodDisruptionBudget +metadata: + name: test-oss-component-image-values-mimir-query-frontend + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: query-frontend + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +spec: + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: query-frontend + maxUnavailable: 1 diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/query-frontend/query-frontend-svc.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/query-frontend/query-frontend-svc.yaml new file mode 100644 index 00000000000..6ee2d39eb6c --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/query-frontend/query-frontend-svc.yaml @@ -0,0 +1,29 @@ +--- +# Source: mimir-distributed/templates/query-frontend/query-frontend-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-oss-component-image-values-mimir-query-frontend + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: query-frontend + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: query-frontend diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/query-scheduler/query-scheduler-dep.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/query-scheduler/query-scheduler-dep.yaml new file mode 100644 index 00000000000..a2e4a0374ad --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/query-scheduler/query-scheduler-dep.yaml @@ -0,0 +1,108 @@ +--- +# Source: mimir-distributed/templates/query-scheduler/query-scheduler-dep.yaml +apiVersion: apps/v1 +kind: Deployment +metadata: + name: test-oss-component-image-values-mimir-query-scheduler + namespace: "citestns" + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: query-scheduler + app.kubernetes.io/managed-by: Helm + annotations: + {} +spec: + replicas: 2 + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: query-scheduler + strategy: + rollingUpdate: + maxSurge: 1 + maxUnavailable: 0 + type: RollingUpdate + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: query-scheduler + annotations: + spec: + serviceAccountName: test-oss-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + containers: + - name: query-scheduler + image: test/query_scheduler:1-query-scheduler + imagePullPolicy: IfNotPresent + args: + - "-target=query-scheduler" + - "-config.expand-env=true" + - "-config.file=/etc/mimir/mimir.yaml" + volumeMounts: + - name: runtime-config + mountPath: /var/mimir + - name: config + mountPath: /etc/mimir + - name: storage + mountPath: /data + - name: active-queries + mountPath: /active-query-tracker + ports: + - name: http-metrics + containerPort: 8080 + protocol: TCP + - name: grpc + containerPort: 9095 + protocol: TCP + livenessProbe: + null + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 45 + resources: + requests: + cpu: 100m + memory: 128Mi + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true + topologySpreadConstraints: + - maxSkew: 1 + topologyKey: kubernetes.io/hostname + whenUnsatisfiable: ScheduleAnyway + labelSelector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: query-scheduler + terminationGracePeriodSeconds: 180 + volumes: + - name: config + configMap: + name: test-oss-component-image-values-mimir-config + items: + - key: "mimir.yaml" + path: "mimir.yaml" + - name: runtime-config + configMap: + name: test-oss-component-image-values-mimir-runtime + - name: storage + emptyDir: {} + - name: active-queries + emptyDir: {} diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/query-scheduler/query-scheduler-pdb.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/query-scheduler/query-scheduler-pdb.yaml new file mode 100644 index 00000000000..e46f3e177f6 --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/query-scheduler/query-scheduler-pdb.yaml @@ -0,0 +1,19 @@ +--- +# Source: mimir-distributed/templates/query-scheduler/query-scheduler-pdb.yaml +apiVersion: policy/v1beta1 +kind: PodDisruptionBudget +metadata: + name: test-oss-component-image-values-mimir-query-scheduler + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: query-scheduler + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +spec: + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: query-scheduler + maxUnavailable: 1 diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/query-scheduler/query-scheduler-svc-headless.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/query-scheduler/query-scheduler-svc-headless.yaml new file mode 100644 index 00000000000..a2336b1a3cd --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/query-scheduler/query-scheduler-svc-headless.yaml @@ -0,0 +1,32 @@ +--- +# Source: mimir-distributed/templates/query-scheduler/query-scheduler-svc-headless.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-oss-component-image-values-mimir-query-scheduler-headless + namespace: "citestns" + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: query-scheduler + app.kubernetes.io/managed-by: Helm + prometheus.io/service-monitor: "false" + annotations: + {} +spec: + type: ClusterIP + clusterIP: None + publishNotReadyAddresses: true + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: query-scheduler diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/query-scheduler/query-scheduler-svc.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/query-scheduler/query-scheduler-svc.yaml new file mode 100644 index 00000000000..d7613e0de90 --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/query-scheduler/query-scheduler-svc.yaml @@ -0,0 +1,29 @@ +--- +# Source: mimir-distributed/templates/query-scheduler/query-scheduler-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-oss-component-image-values-mimir-query-scheduler + namespace: "citestns" + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: query-scheduler + app.kubernetes.io/managed-by: Helm + annotations: + {} +spec: + type: ClusterIP + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: query-scheduler diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/role.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/role.yaml new file mode 100644 index 00000000000..5f172a2fcd0 --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/role.yaml @@ -0,0 +1,16 @@ +--- +# Source: mimir-distributed/templates/role.yaml +apiVersion: rbac.authorization.k8s.io/v1 +kind: Role +metadata: + name: test-oss-component-image-values-mimir + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +rules: +- apiGroups: ['extensions'] + resources: ['podsecuritypolicies'] + verbs: ['use'] + resourceNames: [test-oss-component-image-values-mimir] diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/rolebinding.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/rolebinding.yaml new file mode 100644 index 00000000000..c12e2fc8a5a --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/rolebinding.yaml @@ -0,0 +1,20 @@ +--- +# Source: mimir-distributed/templates/rolebinding.yaml +apiVersion: rbac.authorization.k8s.io/v1 +kind: RoleBinding +metadata: + name: test-oss-component-image-values-mimir + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: Role + name: test-oss-component-image-values-mimir +subjects: +- kind: ServiceAccount + name: test-oss-component-image-values-mimir +- kind: ServiceAccount + name: test-oss-component-image-values-mimir-distributed diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/ruler/ruler-dep.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/ruler/ruler-dep.yaml new file mode 100644 index 00000000000..cde4a53234e --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/ruler/ruler-dep.yaml @@ -0,0 +1,118 @@ +--- +# Source: mimir-distributed/templates/ruler/ruler-dep.yaml +apiVersion: apps/v1 +kind: Deployment +metadata: + name: test-oss-component-image-values-mimir-ruler + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: ruler + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +spec: + replicas: 1 + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: ruler + strategy: + rollingUpdate: + maxSurge: 50% + maxUnavailable: 0 + type: RollingUpdate + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: ruler + app.kubernetes.io/part-of: memberlist + annotations: + namespace: "citestns" + spec: + serviceAccountName: test-oss-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + containers: + - name: ruler + image: test/ruler:1-ruler + imagePullPolicy: IfNotPresent + args: + - "-target=ruler" + - "-config.expand-env=true" + - "-config.file=/etc/mimir/mimir.yaml" + - "-distributor.remote-timeout=10s" + volumeMounts: + - name: config + mountPath: /etc/mimir + - name: runtime-config + mountPath: /var/mimir + - name: storage + mountPath: "/data" + - name: active-queries + mountPath: /active-query-tracker + ports: + - name: http-metrics + containerPort: 8080 + protocol: TCP + - name: grpc + containerPort: 9095 + protocol: TCP + - name: memberlist + containerPort: 7946 + protocol: TCP + livenessProbe: + null + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 45 + resources: + requests: + cpu: 100m + memory: 128Mi + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true + env: + - name: "JAEGER_REPORTER_MAX_QUEUE_SIZE" + value: "1000" + topologySpreadConstraints: + - maxSkew: 1 + topologyKey: kubernetes.io/hostname + whenUnsatisfiable: ScheduleAnyway + labelSelector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: ruler + terminationGracePeriodSeconds: 600 + volumes: + - name: config + configMap: + name: test-oss-component-image-values-mimir-config + items: + - key: "mimir.yaml" + path: "mimir.yaml" + - name: runtime-config + configMap: + name: test-oss-component-image-values-mimir-runtime + - name: storage + emptyDir: {} + - name: active-queries + emptyDir: {} diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/ruler/ruler-pdb.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/ruler/ruler-pdb.yaml new file mode 100644 index 00000000000..532a295c686 --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/ruler/ruler-pdb.yaml @@ -0,0 +1,19 @@ +--- +# Source: mimir-distributed/templates/ruler/ruler-pdb.yaml +apiVersion: policy/v1beta1 +kind: PodDisruptionBudget +metadata: + name: test-oss-component-image-values-mimir-ruler + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: ruler + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +spec: + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: ruler + maxUnavailable: 1 diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/ruler/ruler-svc.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/ruler/ruler-svc.yaml new file mode 100644 index 00000000000..6086f93a8a8 --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/ruler/ruler-svc.yaml @@ -0,0 +1,26 @@ +--- +# Source: mimir-distributed/templates/ruler/ruler-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-oss-component-image-values-mimir-ruler + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: ruler + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: ruler diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/runtime-configmap.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/runtime-configmap.yaml new file mode 100644 index 00000000000..19682e22bcb --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/runtime-configmap.yaml @@ -0,0 +1,15 @@ +--- +# Source: mimir-distributed/templates/runtime-configmap.yaml +apiVersion: v1 +kind: ConfigMap +metadata: + name: test-oss-component-image-values-mimir-runtime + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +data: + runtime.yaml: | + + {} diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/serviceaccount.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/serviceaccount.yaml new file mode 100644 index 00000000000..9e073752729 --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/serviceaccount.yaml @@ -0,0 +1,13 @@ +--- +# Source: mimir-distributed/templates/serviceaccount.yaml +apiVersion: v1 +kind: ServiceAccount +metadata: + name: test-oss-component-image-values-mimir + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/managed-by: Helm + annotations: + {} + namespace: "citestns" diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/smoke-test/smoke-test-job.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/smoke-test/smoke-test-job.yaml new file mode 100644 index 00000000000..1f4c8bdc10d --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/smoke-test/smoke-test-job.yaml @@ -0,0 +1,54 @@ +--- +# Source: mimir-distributed/templates/smoke-test/smoke-test-job.yaml +apiVersion: batch/v1 +kind: Job +metadata: + name: test-oss-component-image-values-mimir-smoke-test + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: smoke-test + app.kubernetes.io/managed-by: Helm + annotations: + "helm.sh/hook": test + namespace: "citestns" +spec: + backoffLimit: 5 + completions: 1 + parallelism: 1 + selector: + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: smoke-test + spec: + serviceAccountName: test-oss-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + initContainers: + [] + containers: + - name: smoke-test + image: test/smoke_test:1-smoke-test + imagePullPolicy: IfNotPresent + args: + - "-target=continuous-test" + - "-activity-tracker.filepath=" + - "-tests.smoke-test" + - "-tests.write-endpoint=http://test-oss-component-image-values-mimir-nginx.citestns.svc:80" + - "-tests.read-endpoint=http://test-oss-component-image-values-mimir-nginx.citestns.svc:80/prometheus" + - "-tests.tenant-id=" + - "-tests.write-read-series-test.num-series=1000" + - "-tests.write-read-series-test.max-query-age=48h" + - "-server.http-listen-port=8080" + volumeMounts: + restartPolicy: OnFailure + volumes: diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/store-gateway/store-gateway-pdb.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/store-gateway/store-gateway-pdb.yaml new file mode 100644 index 00000000000..cb659670790 --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/store-gateway/store-gateway-pdb.yaml @@ -0,0 +1,19 @@ +--- +# Source: mimir-distributed/templates/store-gateway/store-gateway-pdb.yaml +apiVersion: policy/v1beta1 +kind: PodDisruptionBudget +metadata: + name: test-oss-component-image-values-mimir-store-gateway + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: store-gateway + app.kubernetes.io/managed-by: Helm + namespace: "citestns" +spec: + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: store-gateway + maxUnavailable: 1 diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/store-gateway/store-gateway-statefulset.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/store-gateway/store-gateway-statefulset.yaml new file mode 100644 index 00000000000..6c10994cefe --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/store-gateway/store-gateway-statefulset.yaml @@ -0,0 +1,414 @@ +--- +# Source: mimir-distributed/templates/store-gateway/store-gateway-statefulset.yaml +apiVersion: apps/v1 +kind: StatefulSet +metadata: + name: test-oss-component-image-values-mimir-store-gateway-zone-a + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: store-gateway + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + name: "store-gateway-zone-a" + rollout-group: store-gateway + zone: zone-a + annotations: + rollout-max-unavailable: "50" + namespace: "citestns" +spec: + podManagementPolicy: OrderedReady + replicas: 1 + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: store-gateway + rollout-group: store-gateway + zone: zone-a + updateStrategy: + type: OnDelete + serviceName: test-oss-component-image-values-mimir-store-gateway-headless + volumeClaimTemplates: + - apiVersion: v1 + kind: PersistentVolumeClaim + metadata: + name: storage + spec: + accessModes: + - ReadWriteOnce + resources: + requests: + storage: "2Gi" + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: store-gateway + app.kubernetes.io/part-of: memberlist + name: "store-gateway-zone-a" + rollout-group: store-gateway + zone: zone-a + annotations: + namespace: "citestns" + spec: + serviceAccountName: test-oss-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + topologySpreadConstraints: + - maxSkew: 1 + topologyKey: kubernetes.io/hostname + whenUnsatisfiable: ScheduleAnyway + labelSelector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: store-gateway + terminationGracePeriodSeconds: 120 + volumes: + - name: config + configMap: + name: test-oss-component-image-values-mimir-config + items: + - key: "mimir.yaml" + path: "mimir.yaml" + - name: runtime-config + configMap: + name: test-oss-component-image-values-mimir-runtime + - name: active-queries + emptyDir: {} + containers: + - name: store-gateway + image: test/store_gateway:1-store-gateway + imagePullPolicy: IfNotPresent + args: + - "-target=store-gateway" + - "-config.expand-env=true" + - "-config.file=/etc/mimir/mimir.yaml" + - "-store-gateway.sharding-ring.instance-availability-zone=zone-a" + volumeMounts: + - name: config + mountPath: /etc/mimir + - name: runtime-config + mountPath: /var/mimir + - name: storage + mountPath: "/data" + - name: active-queries + mountPath: /active-query-tracker + ports: + - name: http-metrics + containerPort: 8080 + protocol: TCP + - name: grpc + containerPort: 9095 + protocol: TCP + - name: memberlist + containerPort: 7946 + protocol: TCP + livenessProbe: + null + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 60 + resources: + requests: + cpu: 100m + memory: 512Mi + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true + env: + - name: "GOMAXPROCS" + value: "5" + - name: "GOMEMLIMIT" + value: "536870912" + - name: "JAEGER_REPORTER_MAX_QUEUE_SIZE" + value: "1000" +--- +# Source: mimir-distributed/templates/store-gateway/store-gateway-statefulset.yaml +apiVersion: apps/v1 +kind: StatefulSet +metadata: + name: test-oss-component-image-values-mimir-store-gateway-zone-b + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: store-gateway + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + name: "store-gateway-zone-b" + rollout-group: store-gateway + zone: zone-b + annotations: + rollout-max-unavailable: "50" + namespace: "citestns" +spec: + podManagementPolicy: OrderedReady + replicas: 1 + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: store-gateway + rollout-group: store-gateway + zone: zone-b + updateStrategy: + type: OnDelete + serviceName: test-oss-component-image-values-mimir-store-gateway-headless + volumeClaimTemplates: + - apiVersion: v1 + kind: PersistentVolumeClaim + metadata: + name: storage + spec: + accessModes: + - ReadWriteOnce + resources: + requests: + storage: "2Gi" + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: store-gateway + app.kubernetes.io/part-of: memberlist + name: "store-gateway-zone-b" + rollout-group: store-gateway + zone: zone-b + annotations: + namespace: "citestns" + spec: + serviceAccountName: test-oss-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + topologySpreadConstraints: + - maxSkew: 1 + topologyKey: kubernetes.io/hostname + whenUnsatisfiable: ScheduleAnyway + labelSelector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: store-gateway + terminationGracePeriodSeconds: 120 + volumes: + - name: config + configMap: + name: test-oss-component-image-values-mimir-config + items: + - key: "mimir.yaml" + path: "mimir.yaml" + - name: runtime-config + configMap: + name: test-oss-component-image-values-mimir-runtime + - name: active-queries + emptyDir: {} + containers: + - name: store-gateway + image: test/store_gateway:1-store-gateway + imagePullPolicy: IfNotPresent + args: + - "-target=store-gateway" + - "-config.expand-env=true" + - "-config.file=/etc/mimir/mimir.yaml" + - "-store-gateway.sharding-ring.instance-availability-zone=zone-b" + volumeMounts: + - name: config + mountPath: /etc/mimir + - name: runtime-config + mountPath: /var/mimir + - name: storage + mountPath: "/data" + - name: active-queries + mountPath: /active-query-tracker + ports: + - name: http-metrics + containerPort: 8080 + protocol: TCP + - name: grpc + containerPort: 9095 + protocol: TCP + - name: memberlist + containerPort: 7946 + protocol: TCP + livenessProbe: + null + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 60 + resources: + requests: + cpu: 100m + memory: 512Mi + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true + env: + - name: "GOMAXPROCS" + value: "5" + - name: "GOMEMLIMIT" + value: "536870912" + - name: "JAEGER_REPORTER_MAX_QUEUE_SIZE" + value: "1000" +--- +# Source: mimir-distributed/templates/store-gateway/store-gateway-statefulset.yaml +apiVersion: apps/v1 +kind: StatefulSet +metadata: + name: test-oss-component-image-values-mimir-store-gateway-zone-c + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: store-gateway + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + name: "store-gateway-zone-c" + rollout-group: store-gateway + zone: zone-c + annotations: + rollout-max-unavailable: "50" + namespace: "citestns" +spec: + podManagementPolicy: OrderedReady + replicas: 1 + selector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: store-gateway + rollout-group: store-gateway + zone: zone-c + updateStrategy: + type: OnDelete + serviceName: test-oss-component-image-values-mimir-store-gateway-headless + volumeClaimTemplates: + - apiVersion: v1 + kind: PersistentVolumeClaim + metadata: + name: storage + spec: + accessModes: + - ReadWriteOnce + resources: + requests: + storage: "2Gi" + template: + metadata: + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/component: store-gateway + app.kubernetes.io/part-of: memberlist + name: "store-gateway-zone-c" + rollout-group: store-gateway + zone: zone-c + annotations: + namespace: "citestns" + spec: + serviceAccountName: test-oss-component-image-values-mimir + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + seccompProfile: + type: RuntimeDefault + topologySpreadConstraints: + - maxSkew: 1 + topologyKey: kubernetes.io/hostname + whenUnsatisfiable: ScheduleAnyway + labelSelector: + matchLabels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: store-gateway + terminationGracePeriodSeconds: 120 + volumes: + - name: config + configMap: + name: test-oss-component-image-values-mimir-config + items: + - key: "mimir.yaml" + path: "mimir.yaml" + - name: runtime-config + configMap: + name: test-oss-component-image-values-mimir-runtime + - name: active-queries + emptyDir: {} + containers: + - name: store-gateway + image: test/store_gateway:1-store-gateway + imagePullPolicy: IfNotPresent + args: + - "-target=store-gateway" + - "-config.expand-env=true" + - "-config.file=/etc/mimir/mimir.yaml" + - "-store-gateway.sharding-ring.instance-availability-zone=zone-c" + volumeMounts: + - name: config + mountPath: /etc/mimir + - name: runtime-config + mountPath: /var/mimir + - name: storage + mountPath: "/data" + - name: active-queries + mountPath: /active-query-tracker + ports: + - name: http-metrics + containerPort: 8080 + protocol: TCP + - name: grpc + containerPort: 9095 + protocol: TCP + - name: memberlist + containerPort: 7946 + protocol: TCP + livenessProbe: + null + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 60 + resources: + requests: + cpu: 100m + memory: 512Mi + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + readOnlyRootFilesystem: true + env: + - name: "GOMAXPROCS" + value: "5" + - name: "GOMEMLIMIT" + value: "536870912" + - name: "JAEGER_REPORTER_MAX_QUEUE_SIZE" + value: "1000" diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/store-gateway/store-gateway-svc-headless.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/store-gateway/store-gateway-svc-headless.yaml new file mode 100644 index 00000000000..f24129b582e --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/store-gateway/store-gateway-svc-headless.yaml @@ -0,0 +1,32 @@ +--- +# Source: mimir-distributed/templates/store-gateway/store-gateway-svc-headless.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-oss-component-image-values-mimir-store-gateway-headless + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: store-gateway + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + prometheus.io/service-monitor: "false" + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + clusterIP: None + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: store-gateway diff --git a/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/store-gateway/store-gateway-svc.yaml b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/store-gateway/store-gateway-svc.yaml new file mode 100644 index 00000000000..952256a0806 --- /dev/null +++ b/operations/helm/tests/test-oss-component-image-values-generated/mimir-distributed/templates/store-gateway/store-gateway-svc.yaml @@ -0,0 +1,105 @@ +--- +# Source: mimir-distributed/templates/store-gateway/store-gateway-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-oss-component-image-values-mimir-store-gateway-zone-a + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: store-gateway + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + name: "store-gateway-zone-a" + rollout-group: store-gateway + zone: zone-a + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: store-gateway + rollout-group: store-gateway + zone: zone-a +--- +# Source: mimir-distributed/templates/store-gateway/store-gateway-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-oss-component-image-values-mimir-store-gateway-zone-b + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: store-gateway + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + name: "store-gateway-zone-b" + rollout-group: store-gateway + zone: zone-b + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: store-gateway + rollout-group: store-gateway + zone: zone-b +--- +# Source: mimir-distributed/templates/store-gateway/store-gateway-svc.yaml +apiVersion: v1 +kind: Service +metadata: + name: test-oss-component-image-values-mimir-store-gateway-zone-c + labels: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: store-gateway + app.kubernetes.io/part-of: memberlist + app.kubernetes.io/managed-by: Helm + name: "store-gateway-zone-c" + rollout-group: store-gateway + zone: zone-c + annotations: + {} + namespace: "citestns" +spec: + type: ClusterIP + ports: + - port: 8080 + protocol: TCP + name: http-metrics + targetPort: http-metrics + - port: 9095 + protocol: TCP + name: grpc + targetPort: grpc + selector: + app.kubernetes.io/name: mimir + app.kubernetes.io/instance: test-oss-component-image-values + app.kubernetes.io/component: store-gateway + rollout-group: store-gateway + zone: zone-c