From ffbb5df19e54d0ee7106f8c27410ad0e3b27e116 Mon Sep 17 00:00:00 2001 From: Deniz Erdogan Date: Fri, 17 Jun 2022 14:13:04 +0200 Subject: [PATCH 1/6] bump mediawiki chart to 0.10.6 --- charts/mediawiki/Chart.yaml | 2 +- charts/mediawiki/README.md | 1 + charts/mediawiki/templates/_helpers.tpl | 3 +++ charts/mediawiki/values.yaml | 1 + 4 files changed, 6 insertions(+), 1 deletion(-) diff --git a/charts/mediawiki/Chart.yaml b/charts/mediawiki/Chart.yaml index 3dbe590..6577b40 100644 --- a/charts/mediawiki/Chart.yaml +++ b/charts/mediawiki/Chart.yaml @@ -2,7 +2,7 @@ apiVersion: v1 appVersion: "1.37" description: A Helm wbstack flavoured MediaWiki name: mediawiki -version: 0.10.5 +version: 0.10.6 home: https://github.com/wbstack maintainers: - name: WBstack diff --git a/charts/mediawiki/README.md b/charts/mediawiki/README.md index 3ab2cc6..7bf1eaf 100644 --- a/charts/mediawiki/README.md +++ b/charts/mediawiki/README.md @@ -2,6 +2,7 @@ ## Changelog +- 0.10.6: Added `mw.settings.allowedProxyCidr` to set $wgCdnServersNoPurge - 0.10.5: New MW release with updated CirrusSearch sharding config, we missed one index. - 0.10.4: New MW release with CirrusSearch sharding config - 0.10.3: Bump version number to trigger new chart release diff --git a/charts/mediawiki/templates/_helpers.tpl b/charts/mediawiki/templates/_helpers.tpl index 2c4a400..90de1e6 100644 --- a/charts/mediawiki/templates/_helpers.tpl +++ b/charts/mediawiki/templates/_helpers.tpl @@ -157,6 +157,9 @@ Common deployment environment variables {{- end -}} +- name: MW_ALLOWED_PROXY_CIDR + value: {{ .Values.mw.settings.allowedProxyCidr }} + {{- end -}} {{/* diff --git a/charts/mediawiki/values.yaml b/charts/mediawiki/values.yaml index d83d259..2887ea4 100644 --- a/charts/mediawiki/values.yaml +++ b/charts/mediawiki/values.yaml @@ -12,6 +12,7 @@ image: mw: settings: logToStdErr: false + allowedProxyCidr: "" db: master: someHostName replica: someHostName From 809aa1609043f7e6baaddea049d247a7026c3dfb Mon Sep 17 00:00:00 2001 From: Deniz Erdogan Date: Fri, 17 Jun 2022 14:29:20 +0200 Subject: [PATCH 2/6] Add new mw tag placeholder --- charts/mediawiki/values.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/charts/mediawiki/values.yaml b/charts/mediawiki/values.yaml index 2887ea4..c780bda 100644 --- a/charts/mediawiki/values.yaml +++ b/charts/mediawiki/values.yaml @@ -6,7 +6,7 @@ replicaCount: image: repository: ghcr.io/wbstack/mediawiki - tag: "1.37-7.4-20220513-fp-beta-0" + tag: "1.37-7.4-20220513-fp-beta-0" # TODO change this to new mw release! pullPolicy: IfNotPresent mw: From b360b8a4fbb337c30263c5e3f2178f311451e89a Mon Sep 17 00:00:00 2001 From: Deniz Erdogan Date: Tue, 21 Jun 2022 11:41:32 +0200 Subject: [PATCH 3/6] switch image tag to 1.37-7.4-20220621-fp-beta-0 --- charts/mediawiki/values.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/charts/mediawiki/values.yaml b/charts/mediawiki/values.yaml index c780bda..9760297 100644 --- a/charts/mediawiki/values.yaml +++ b/charts/mediawiki/values.yaml @@ -6,7 +6,7 @@ replicaCount: image: repository: ghcr.io/wbstack/mediawiki - tag: "1.37-7.4-20220513-fp-beta-0" # TODO change this to new mw release! + tag: "1.37-7.4-20220621-fp-beta-0" pullPolicy: IfNotPresent mw: From df40652e3489b1e5a1a05f1b7586c925ea76133c Mon Sep 17 00:00:00 2001 From: Deniz Erdogan Date: Tue, 21 Jun 2022 11:48:36 +0200 Subject: [PATCH 4/6] Update Readme --- charts/mediawiki/README.md | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/charts/mediawiki/README.md b/charts/mediawiki/README.md index 7bf1eaf..5ee252c 100644 --- a/charts/mediawiki/README.md +++ b/charts/mediawiki/README.md @@ -1,5 +1,14 @@ # wbstack mediawiki +## Settings +### mw.settings.allowedProxyCidr +Sets `$wgCdnServersNoPurge` in mediawiki. + +In order to see which IP ranges is used for a GKE cluster you can run the following command: +``` +kubectl get ds kube-proxy -n kube-system -o=jsonpath="{.spec.template.spec.containers[0].command}" | grep -Po '\-\-cluster\-cidr=[^ ]*' | cut -d'=' -f2 | tr -d '"]' +``` + ## Changelog - 0.10.6: Added `mw.settings.allowedProxyCidr` to set $wgCdnServersNoPurge From 7854dfb48462256d4bac9be052363b70caaa1bbe Mon Sep 17 00:00:00 2001 From: Deniz Erdogan Date: Tue, 21 Jun 2022 14:46:00 +0200 Subject: [PATCH 5/6] Fix templating --- charts/mediawiki/templates/_helpers.tpl | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/charts/mediawiki/templates/_helpers.tpl b/charts/mediawiki/templates/_helpers.tpl index 90de1e6..8d2e8a9 100644 --- a/charts/mediawiki/templates/_helpers.tpl +++ b/charts/mediawiki/templates/_helpers.tpl @@ -157,8 +157,10 @@ Common deployment environment variables {{- end -}} +{{- if .Values.mw.smtp.smtpPasswordSecretName }} - name: MW_ALLOWED_PROXY_CIDR - value: {{ .Values.mw.settings.allowedProxyCidr }} + value: {{ .Values.mw.settings.allowedProxyCidr | quote }} +{{- end -}} {{- end -}} From 35e106e8f99a964a99bc5f7db0376afcbbe3a9c6 Mon Sep 17 00:00:00 2001 From: Deniz Erdogan <91744937+deer-wmde@users.noreply.github.com> Date: Tue, 21 Jun 2022 17:16:13 +0200 Subject: [PATCH 6/6] Update charts/mediawiki/templates/_helpers.tpl Co-authored-by: Tobias --- charts/mediawiki/templates/_helpers.tpl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/charts/mediawiki/templates/_helpers.tpl b/charts/mediawiki/templates/_helpers.tpl index 8d2e8a9..cecff39 100644 --- a/charts/mediawiki/templates/_helpers.tpl +++ b/charts/mediawiki/templates/_helpers.tpl @@ -157,7 +157,7 @@ Common deployment environment variables {{- end -}} -{{- if .Values.mw.smtp.smtpPasswordSecretName }} +{{- if .Values.mw.settings.allowedProxyCidr }} - name: MW_ALLOWED_PROXY_CIDR value: {{ .Values.mw.settings.allowedProxyCidr | quote }} {{- end -}}