From 8bf4e12edf3eb2b2b8500e7e4d0bddc2b862bfae Mon Sep 17 00:00:00 2001 From: zirain Date: Sat, 17 Jun 2023 04:03:42 +0800 Subject: [PATCH] helm: fix resource not respect namespace (#9678) **What this PR does / why we need it**: this PR make all resources have some behavior when running `helm template loki grafana/loki --name istio-system` istio use it here: https://github.com/istio/istio/blob/master/manifests/addons/gen.sh#L89 **Which issue(s) this PR fixes**: Fixes # **Special notes for your reviewer**: **Checklist** - [x] Reviewed the [`CONTRIBUTING.md`](https://github.com/grafana/loki/blob/main/CONTRIBUTING.md) guide (**required**) - [ ] Documentation added - [ ] Tests updated - [ ] `CHANGELOG.md` updated - [ ] Changes that require user attention or interaction to upgrade are documented in `docs/sources/upgrading/_index.md` - [ ] For Helm chart changes bump the Helm chart version in `production/helm/loki/Chart.yaml` and update `production/helm/loki/CHANGELOG.md` and `production/helm/loki/README.md`. [Example PR](https://github.com/grafana/loki/commit/d10549e3ece02120974929894ee333d07755d213) Signed-off-by: hejianpeng --- production/helm/loki/templates/config.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/production/helm/loki/templates/config.yaml b/production/helm/loki/templates/config.yaml index 34d8176a69..101abc353e 100644 --- a/production/helm/loki/templates/config.yaml +++ b/production/helm/loki/templates/config.yaml @@ -7,6 +7,7 @@ kind: ConfigMap {{- end }} metadata: name: {{ tpl .Values.loki.externalConfigSecretName . }} + namespace: {{ $.Release.Namespace }} labels: {{- include "loki.labels" . | nindent 4 }} {{- if eq .Values.loki.configStorageType "Secret" }}