From 2c792363bf946506044dd02d73935dd174e6b941 Mon Sep 17 00:00:00 2001 From: Cansu Kavili Date: Mon, 13 Apr 2020 14:03:19 +0200 Subject: [PATCH 1/5] ocp hack added --- packages/wekan-oidc/oidc_server.js | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/wekan-oidc/oidc_server.js b/packages/wekan-oidc/oidc_server.js index c6d7deabc..745f68e85 100644 --- a/packages/wekan-oidc/oidc_server.js +++ b/packages/wekan-oidc/oidc_server.js @@ -11,6 +11,7 @@ OAuth.registerService('oidc', 2, null, function (query) { var userinfo = getUserInfo(accessToken); if (userinfo.ocs) userinfo = userinfo.ocs.data; // Nextcloud hack + if (userinfo.metadata) userinfo = userinfo.metadata // Openshift hack if (debug) console.log('XXX: userinfo:', userinfo); var serviceData = {}; From 8ac305778a73ccad65b94cca8c2f1b1f35698de8 Mon Sep 17 00:00:00 2001 From: Cansu Kavili Date: Wed, 15 Apr 2020 09:50:07 +0200 Subject: [PATCH 2/5] Add env parameters if specified in values file --- helm/wekan/templates/deployment.yaml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/helm/wekan/templates/deployment.yaml b/helm/wekan/templates/deployment.yaml index e5bf2018a..68dbf75c8 100644 --- a/helm/wekan/templates/deployment.yaml +++ b/helm/wekan/templates/deployment.yaml @@ -37,6 +37,12 @@ spec: value: {{ .Values.root_url | default "https://wekan.local" | quote }} - name: MONGO_URL value: "{{ template "mongodb-replicaset.url" . }}" + {{- range $key := .Values.env }} + {{- if .value }} + - name: {{ .name }} + value: {{ .value | quote }} + {{- end }} + {{- end }} livenessProbe: httpGet: path: / From 60384be5fffc1d78501e93fcc311faf24f4d393e Mon Sep 17 00:00:00 2001 From: Cansu Kavili Date: Wed, 15 Apr 2020 09:50:30 +0200 Subject: [PATCH 3/5] add annotations if specified in values file --- helm/wekan/templates/serviceaccount.yaml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/helm/wekan/templates/serviceaccount.yaml b/helm/wekan/templates/serviceaccount.yaml index 58696cb6e..543e58d46 100644 --- a/helm/wekan/templates/serviceaccount.yaml +++ b/helm/wekan/templates/serviceaccount.yaml @@ -2,6 +2,10 @@ apiVersion: v1 kind: ServiceAccount metadata: +{{- if .Values.serviceAccounts.annotations }} + annotations: +{{ .Values.serviceAccounts.annotations | indent 4}} +{{- end }} labels: app: {{ template "wekan.name" . }} chart: {{ template "wekan.chart" . }} From 61d582ffd985c9c3c6208a97208eda24608a1612 Mon Sep 17 00:00:00 2001 From: Cansu Kavili Date: Wed, 15 Apr 2020 09:52:34 +0200 Subject: [PATCH 4/5] updated with env and annotation parameters --- helm/wekan/values.yaml | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/helm/wekan/values.yaml b/helm/wekan/values.yaml index 8211f495f..cadb06453 100644 --- a/helm/wekan/values.yaml +++ b/helm/wekan/values.yaml @@ -8,6 +8,7 @@ serviceAccounts: create: true name: "" + annotations: "" ## Wekan image configuration ## @@ -59,10 +60,10 @@ ingress: # hosts: # - wekan-example.local - route: - enabled: false +route: + enabled: false -resources: +resources: requests: memory: 128Mi cpu: 300m From 93f8ff946f62894c35380e744c25322a61efc108 Mon Sep 17 00:00:00 2001 From: Cansu Kavili Date: Wed, 15 Apr 2020 09:54:22 +0200 Subject: [PATCH 5/5] updated with env and annotation parameters --- helm/wekan/values.yaml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/helm/wekan/values.yaml b/helm/wekan/values.yaml index cadb06453..78136af3a 100644 --- a/helm/wekan/values.yaml +++ b/helm/wekan/values.yaml @@ -30,7 +30,9 @@ credentials: ## Specify additional environmental variables for the Deployment ## -env: {} +env: + - name: "" + value: "" service: type: NodePort