Skip to content

Commit 5b7c5ec

Browse files
committed
feat: upgrade helm charts for nl portal and config panel
* fix minor issues in existing templating * add support for nl-portal 3.0.x * fix probes for nl-portal and configuration panel
1 parent c5fa534 commit 5b7c5ec

29 files changed

Lines changed: 398 additions & 247 deletions

File tree

README.md

Lines changed: 72 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,78 @@ helm upgrade --install nl-portal-backend nl-portal/nl-portal-backend \
3636

3737
### NL Portal
3838

39+
#### 3.0.0
40+
41+
**Breaking changes:**
42+
43+
- `ingress.host` renamed to `ingress.hosts` (now a list) in nl-portal-backend and nl-portal-frontend
44+
- `settings.app.features.configurationPanel.enabled` now defaults to `false` — explicitly enable if using config panel
45+
- nl-portal-configpanel-backend: `secretEnvVars` pattern now coexists with new `existingSecret` option; both disable chart-managed Secret
46+
- nl-portal-configpanel-backend: fixed `settings.app.configServerToken` → use `settings.app.serverToken`
47+
- nl-portal-configpanel-backend: Secret now uses `stringData` (was broken `data` without base64 encoding)
48+
- nl-portal-configpanel chart version jumps from 1.x to 3.0.0 (aligns chart family with nl-portal major version)
49+
- `image.tag` default on configpanel charts changed from `"latest"` to `""` (uses appVersion)
50+
- HPA API updated from `autoscaling/v2beta1` to `autoscaling/v2`
51+
- Minimum Kubernetes version: 1.23 (`kubeVersion: ">=1.23.0"`)
52+
53+
**New features:**
54+
55+
Backend new env vars:
56+
- `CONFIGURATION_PANEL_APPLICATION_NAME` — application name for config panel integration
57+
- `NLPORTAL_CONFIG_CATALOGIAPI_PROPERTIES_DOCUMENTTYPEURL` — Catalogi API document type URL
58+
- `NLPORTAL_CONFIG_CATALOGIAPI_PROPERTIES_RSIN` — Catalogi API RSIN
59+
- `NLPORTAL_CONFIG_OPENKLANT2_PROPERTIES_CONTACTGEGEVENSAPIURL` — OpenKlant2 contact details API URL
60+
- `NLPORTAL_CONFIG_OPENPRODUCT_ENABLED` — enable OpenProduct module
61+
- `NLPORTAL_CONFIG_OPENPRODUCT_PROPERTIES_PRODUCTAPIURL` — OpenProduct product API URL
62+
- `NLPORTAL_CONFIG_OPENPRODUCT_PROPERTIES_PRODUCTTYPEAPIURL` — OpenProduct product type API URL
63+
- `NLPORTAL_CONFIG_OPENPRODUCT_PROPERTIES_TOKEN` — OpenProduct API token (secret)
64+
- `NLPORTAL_CONFIG_OPENPRODUCT_PROPERTIES_DMN_CLIENTID` — OpenProduct DMN client ID
65+
- `NLPORTAL_CONFIG_OPENPRODUCT_PROPERTIES_DMN_USERNAME` — OpenProduct DMN username
66+
- `NLPORTAL_CONFIG_OPENPRODUCT_PROPERTIES_DMN_SECRET` — OpenProduct DMN secret (secret)
67+
- `NLPORTAL_CONFIG_OPENPRODUCT_PROPERTIES_DMN_PASSWORD` — OpenProduct DMN password (secret)
68+
- `NLPORTAL_CONFIG_THEME_LOGO` — theme logo URL
69+
- `NLPORTAL_CONFIG_THEME_STYLE` — theme style configuration
70+
71+
Frontend new env vars:
72+
- `USE_THEME_API` — whether to fetch theme from backend API
73+
- `OIDC_AUTO_IDLE_SESSION_LOGOUT` — enable automatic logout after idle timeout
74+
- `OIDC_IDLE_TIMEOUT_MINUTES` — idle timeout in minutes before automatic logout
75+
- `MESSAGE_COUNT_ENABLE` — enable message count polling
76+
77+
Other improvements:
78+
- Frontend: `startupProbe`, `extraVolumes`/`extraVolumeMounts` support
79+
- HPA now supports memory metric via `autoscaling.targetMemoryUtilizationPercentage`
80+
- Backend probes now use proper `/actuator/health/*` endpoints instead of GraphQL
81+
82+
**Migration:**
83+
84+
```yaml
85+
# Ingress: host → hosts (backend and frontend)
86+
# Before (2.x)
87+
ingress:
88+
host: "portal.example.com"
89+
90+
# After (3.x)
91+
ingress:
92+
hosts:
93+
- portal.example.com
94+
```
95+
96+
```yaml
97+
# Configpanel-backend: existingSecret option added
98+
# Before (2.x) - only secretEnvVars for external secrets
99+
secretEnvVars:
100+
- name: DATABASE_PASSWORD
101+
valueFrom:
102+
secretKeyRef:
103+
name: my-secret
104+
key: password
105+
106+
# After (3.x) - can also use existingSecret for whole secret
107+
existingSecret: my-secret
108+
# Or keep using secretEnvVars for partial secret injection
109+
```
110+
39111
#### 2.1.0
40112

41113
- Moved `NLPORTAL_CONFIG_ZAKENAPI_PROPERTIES_SECRET` and `NLPORTAL_CONFIG_CATALOGIAPI_PROPERTIES_SECRET` secrets from ConfigMap into Secret

charts/nl-portal-backend/nl-portal-backend/Chart.yaml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
11
apiVersion: v2
2-
appVersion: 2.x.y
2+
appVersion: 3.0.x
33
description: Nl Portal backend Helm chart to be used in Kubernetes clusters.
4+
kubeVersion: ">=1.23.0"
45
name: nl-portal-backend
56
type: application
6-
version: 2.1.0
7+
version: 3.0.0
78

89
dependencies:
910
- name: postgresql

charts/nl-portal-backend/nl-portal-backend/templates/NOTES.txt

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
11
1. Get the application URL by running these commands:
22
{{- if .Values.ingress.enabled }}
3-
{{- range $host := .Values.ingress.hosts }}
4-
{{- range .paths }}
5-
http{{ if $.Values.ingress.tls }}s{{ end }}://{{ $host.host }}{{ .path }}
6-
{{- end }}
3+
{{- range .Values.ingress.hosts }}
4+
http{{ if $.Values.ingress.tls }}s{{ end }}://{{ . }}/graphql
5+
http{{ if $.Values.ingress.tls }}s{{ end }}://{{ . }}/api
76
{{- end }}
87
{{- else if contains "NodePort" .Values.service.type }}
98
export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "nl-portal-backend.fullname" . }})

charts/nl-portal-backend/nl-portal-backend/templates/configmap.yaml

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
apiVersion: v1
1414
kind: ConfigMap
1515
metadata:
16-
name: {{ template "nl-portal-backend.fullname" . }}
16+
name: {{ include "nl-portal-backend.fullname" . }}
1717
labels:
1818
{{- include "nl-portal-backend.labels" . | nindent 4 }}
1919
data:
@@ -32,6 +32,7 @@ data:
3232

3333
CONFIGURATION_PANEL_ENABLED: {{ .Values.settings.app.features.configurationPanel.enabled | quote }}
3434
CONFIGURATION_PANEL_URI: {{ .Values.settings.app.features.configurationPanel.uri | quote }}
35+
CONFIGURATION_PANEL_APPLICATION_NAME: {{ .Values.settings.app.features.configurationPanel.applicationName | quote }}
3536

3637
# Authentication
3738
NLPORTAL_AUTHENTICATION_MACHTINGSDIENST_RESOURCEURL: {{ .Values.settings.services.authentication.machtingsdienst.resourceUrl | quote }}
@@ -45,6 +46,8 @@ data:
4546
NLPORTAL_CONFIG_CATALOGIAPI_ENABLED: {{ .Values.settings.services.catalogiapi.enabled | quote }}
4647
NLPORTAL_CONFIG_CATALOGIAPI_PROPERTIES_URL: {{ .Values.settings.services.catalogiapi.properties.url | quote }}
4748
NLPORTAL_CONFIG_CATALOGIAPI_PROPERTIES_CLIENTID: {{ .Values.settings.services.catalogiapi.properties.clientId | quote }}
49+
NLPORTAL_CONFIG_CATALOGIAPI_PROPERTIES_DOCUMENTTYPEURL: {{ .Values.settings.services.catalogiapi.properties.documentTypeUrl | quote }}
50+
NLPORTAL_CONFIG_CATALOGIAPI_PROPERTIES_RSIN: {{ .Values.settings.services.catalogiapi.properties.rsin | quote }}
4851

4952
# DocumentenAPIs
5053
NLPORTAL_CONFIG_DOCUMENTENAPIS_ENABLED: {{ .Values.settings.services.documentenapis.enabled | quote }}
@@ -79,6 +82,14 @@ data:
7982
# OpenKlant2
8083
NLPORTAL_CONFIG_OPENKLANT2_ENABLED: {{ .Values.settings.services.openklant2.enabled | quote }}
8184
NLPORTAL_CONFIG_OPENKLANT2_PROPERTIES_KLANTINTERACTIESAPIURL: {{ .Values.settings.services.openklant2.properties.klantinteractiesApiUrl | quote }}
85+
NLPORTAL_CONFIG_OPENKLANT2_PROPERTIES_CONTACTGEGEVENSAPIURL: {{ .Values.settings.services.openklant2.properties.contactgegevensApiUrl | quote }}
86+
87+
# OpenProduct
88+
NLPORTAL_CONFIG_OPENPRODUCT_ENABLED: {{ .Values.settings.services.openproduct.enabled | quote }}
89+
NLPORTAL_CONFIG_OPENPRODUCT_PROPERTIES_PRODUCTAPIURL: {{ .Values.settings.services.openproduct.properties.productApiUrl | quote }}
90+
NLPORTAL_CONFIG_OPENPRODUCT_PROPERTIES_PRODUCTTYPEAPIURL: {{ .Values.settings.services.openproduct.properties.productTypeApiUrl | quote }}
91+
NLPORTAL_CONFIG_OPENPRODUCT_PROPERTIES_DMN_CLIENTID: {{ .Values.settings.services.openproduct.properties.dmn.clientId | quote }}
92+
NLPORTAL_CONFIG_OPENPRODUCT_PROPERTIES_DMN_USERNAME: {{ .Values.settings.services.openproduct.properties.dmn.username | quote }}
8293

8394
# HaalCentraal2
8495
NLPORTAL_CONFIG_HAALCENTRAAL2_ENABLED: {{ .Values.settings.services.haalcentraal2.enabled | quote }}
@@ -122,6 +133,10 @@ data:
122133
NLPORTAL_CONFIG_PREFILL_ENABLED: {{ .Values.settings.services.prefill.enabled | quote }}
123134
NLPORTAL_CONFIG_PREFILL_PROPERTIES_TYPEURL: {{ .Values.settings.services.prefill.properties.typeUrl | quote }}
124135

136+
# Theme
137+
NLPORTAL_CONFIG_THEME_LOGO: {{ .Values.settings.theme.logo | quote }}
138+
NLPORTAL_CONFIG_THEME_STYLE: {{ .Values.settings.theme.style | quote }}
139+
125140
# Payment Direct
126141
NLPORTAL_CONFIG_PAYMENT_DIRECT_ENABLED: {{ .Values.settings.services.payment.direct.enabled | quote }}
127142
NLPORTAL_CONFIG_PAYMENT_DIRECT_PROPERTIES_URL: {{ .Values.settings.services.payment.direct.properties.url | quote }}

charts/nl-portal-backend/nl-portal-backend/templates/hpa.yaml

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{{- if .Values.autoscaling.enabled }}
2-
apiVersion: autoscaling/v2beta1
2+
apiVersion: autoscaling/v2
33
kind: HorizontalPodAutoscaler
44
metadata:
55
name: {{ include "nl-portal-backend.fullname" . }}
@@ -13,16 +13,20 @@ spec:
1313
minReplicas: {{ .Values.autoscaling.minReplicas }}
1414
maxReplicas: {{ .Values.autoscaling.maxReplicas }}
1515
metrics:
16-
{{- if .Values.autoscaling.targetCPUUtilizationPercentage }}
16+
{{- with .Values.autoscaling.targetCPUUtilizationPercentage }}
1717
- type: Resource
1818
resource:
1919
name: cpu
20-
targetAverageUtilization: {{ .Values.autoscaling.targetCPUUtilizationPercentage }}
20+
target:
21+
type: Utilization
22+
averageUtilization: {{ . }}
2123
{{- end }}
22-
{{- if .Values.autoscaling.targetMemoryUtilizationPercentage }}
24+
{{- with .Values.autoscaling.targetMemoryUtilizationPercentage }}
2325
- type: Resource
2426
resource:
2527
name: memory
26-
targetAverageUtilization: {{ .Values.autoscaling.targetMemoryUtilizationPercentage }}
28+
target:
29+
type: Utilization
30+
averageUtilization: {{ . }}
2731
{{- end }}
2832
{{- end }}
Lines changed: 9 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,6 @@
11
{{- if .Values.ingress.enabled -}}
22
{{- $fullName := include "nl-portal-backend.fullname" . -}}
3-
{{- $svcPort := .Values.service.port -}}
4-
{{- if and .Values.ingress.className (not (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion)) }}
5-
{{- if not (hasKey .Values.ingress.annotations "kubernetes.io/ingress.class") }}
6-
{{- $_ := set .Values.ingress.annotations "kubernetes.io/ingress.class" .Values.ingress.className}}
7-
{{- end }}
8-
{{- end }}
9-
{{- if semverCompare ">=1.19-0" .Capabilities.KubeVersion.GitVersion -}}
103
apiVersion: networking.k8s.io/v1
11-
{{- else if semverCompare ">=1.14-0" .Capabilities.KubeVersion.GitVersion -}}
12-
apiVersion: networking.k8s.io/v1beta1
13-
{{- else -}}
14-
apiVersion: extensions/v1beta1
15-
{{- end }}
164
kind: Ingress
175
metadata:
186
name: {{ $fullName }}
@@ -23,12 +11,12 @@ metadata:
2311
{{- toYaml . | nindent 4 }}
2412
{{- end }}
2513
spec:
26-
{{- if and .Values.ingress.className (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion) }}
27-
ingressClassName: {{ .Values.ingress.className }}
14+
{{- with .Values.ingress.className }}
15+
ingressClassName: {{ . }}
2816
{{- end }}
29-
{{- if .Values.ingress.tls }}
17+
{{- with .Values.ingress.tls }}
3018
tls:
31-
{{- range .Values.ingress.tls }}
19+
{{- range . }}
3220
- hosts:
3321
{{- range .hosts }}
3422
- {{ . | quote }}
@@ -37,21 +25,23 @@ spec:
3725
{{- end }}
3826
{{- end }}
3927
rules:
40-
- host: {{ .Values.ingress.host | quote }}
28+
{{- range .Values.ingress.hosts }}
29+
- host: {{ . | quote }}
4130
http:
4231
paths:
4332
- path: "/graphql"
4433
pathType: "Prefix"
4534
backend:
4635
service:
47-
name: {{ include "nl-portal-backend.fullname" . }}
36+
name: {{ $fullName }}
4837
port:
4938
name: http
5039
- path: "/api"
5140
pathType: "Prefix"
5241
backend:
5342
service:
54-
name: {{ include "nl-portal-backend.fullname" . }}
43+
name: {{ $fullName }}
5544
port:
5645
name: http
46+
{{- end }}
5747
{{- end }}

charts/nl-portal-backend/nl-portal-backend/templates/secret.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,11 @@ stringData:
3535
# OpenKlant2
3636
NLPORTAL_CONFIG_OPENKLANT2_PROPERTIES_TOKEN: {{ .Values.settings.services.openklant2.properties.token | quote }}
3737

38+
# OpenProduct
39+
NLPORTAL_CONFIG_OPENPRODUCT_PROPERTIES_TOKEN: {{ .Values.settings.services.openproduct.properties.token | quote }}
40+
NLPORTAL_CONFIG_OPENPRODUCT_PROPERTIES_DMN_SECRET: {{ .Values.settings.services.openproduct.properties.dmn.secret | quote }}
41+
NLPORTAL_CONFIG_OPENPRODUCT_PROPERTIES_DMN_PASSWORD: {{ .Values.settings.services.openproduct.properties.dmn.password | quote }}
42+
3843
# HaalCentraal BRP
3944
NLPORTAL_CONFIG_HAALCENTRAAL_BRP_PROPERTIES_APIKEY: {{ .Values.settings.services.haalcentraal_brp.properties.apiKey | quote }}
4045
NLPORTAL_CONFIG_HAALCENTRAAL_BRP_PROPERTIES_SSL_KEY_KEY: {{ .Values.settings.services.haalcentraal_brp.properties.ssl.key.key | quote }}

charts/nl-portal-backend/nl-portal-backend/values.yaml

Lines changed: 32 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -47,40 +47,37 @@ service:
4747
ingress:
4848
enabled: false
4949
className: ""
50-
annotations:
51-
{}
50+
annotations: {}
5251
# kubernetes.io/ingress.class: nginx
5352
# kubernetes.io/tls-acme: "true"
54-
host: your-nl-portal.example.com
55-
53+
hosts:
54+
- your-nl-portal.example.com
5655
tls: []
5756
# - secretName: chart-example-tls
5857
# hosts:
5958
# - chart-example.local
6059

6160
startupProbe:
6261
httpGet:
63-
path: /graphql?query=%7B__typename%7D
62+
path: /actuator/health
6463
port: http
6564
failureThreshold: 90
6665
periodSeconds: 10
6766
livenessProbe:
68-
enabled: true
6967
httpGet:
70-
path: /graphql?query=%7B__typename%7D
68+
path: /actuator/health/liveness
7169
port: http
72-
initialDelaySeconds: 120
70+
initialDelaySeconds: 10
7371
periodSeconds: 10
7472
timeoutSeconds: 1
7573
failureThreshold: 6
7674
successThreshold: 1
7775

7876
readinessProbe:
79-
enabled: true
8077
httpGet:
81-
path: /graphql?query=%7B__typename%7D
78+
path: /actuator/health/readiness
8279
port: http
83-
initialDelaySeconds: 120
80+
initialDelaySeconds: 10
8481
periodSeconds: 10
8582
timeoutSeconds: 1
8683
failureThreshold: 6
@@ -190,10 +187,11 @@ settings:
190187
unsecured: ""
191188
features:
192189
configurationPanel:
193-
enabled: true
190+
enabled: false
194191
uri: ""
195192
# -- If using existingSecret, set via key: CONFIGURATION_PANEL_TOKEN
196193
token:
194+
applicationName: ""
197195

198196

199197
services:
@@ -216,6 +214,8 @@ settings:
216214
clientId: ""
217215
# -- If using existingSecret, set via key: NLPORTAL_CONFIG_CATALOGIAPI_PROPERTIES_SECRET
218216
secret: ""
217+
documentTypeUrl: ""
218+
rsin: ""
219219

220220
documentenapis:
221221
enabled: false
@@ -273,6 +273,22 @@ settings:
273273
klantinteractiesApiUrl: ""
274274
# -- If using existingSecret, set via key: NLPORTAL_CONFIG_OPENKLANT2_PROPERTIES_TOKEN
275275
token: ""
276+
contactgegevensApiUrl: ""
277+
278+
openproduct:
279+
enabled: false
280+
properties:
281+
productApiUrl: ""
282+
productTypeApiUrl: ""
283+
# -- If using existingSecret, set via key: NLPORTAL_CONFIG_OPENPRODUCT_PROPERTIES_TOKEN
284+
token: ""
285+
dmn:
286+
clientId: ""
287+
# -- If using existingSecret, set via key: NLPORTAL_CONFIG_OPENPRODUCT_PROPERTIES_DMN_SECRET
288+
secret: ""
289+
username: ""
290+
# -- If using existingSecret, set via key: NLPORTAL_CONFIG_OPENPRODUCT_PROPERTIES_DMN_PASSWORD
291+
password: ""
276292

277293
haalcentraal2:
278294
enabled: false
@@ -380,3 +396,7 @@ settings:
380396
shaOutKey: ""
381397
failureUrl: ""
382398
successUrl: ""
399+
400+
theme:
401+
logo: ""
402+
style: ""
Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
apiVersion: v2
22
appVersion: 2.0.0
33
description: NL-Portal Configuration Panel Helm chart to be used in Kubernetes clusters.
4+
kubeVersion: ">=1.23.0"
45
name: nl-portal-configpanel-backend
56
type: application
6-
version: 1.0.2
7+
version: 3.0.0

charts/nl-portal-configpanel-backend/nl-portal-configpanel-backend/templates/configmap.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
1-
---
21
apiVersion: v1
32
kind: ConfigMap
43
metadata:
5-
name: {{ template "nl-portal-configpanel-backend.fullname" . }}
4+
name: {{ include "nl-portal-configpanel-backend.fullname" . }}
65
labels:
76
{{- include "nl-portal-configpanel-backend.labels" . | nindent 4 }}
87
data:
98
LOGLEVEL: {{ .Values.settings.app.logLevel | quote }}
10-
DATABASE_URL: {{ .Values.settings.database.url | quote }}
9+
DATABASE_URL: {{ required "You must set settings.database.url" .Values.settings.database.url | quote }}
1110
JWKS_URI: {{ .Values.settings.auth.jwksURI | quote }}
1211
CONFIG_SERVER_PREFIX: {{ .Values.settings.app.serverPrefix | quote }}
1312
CONFIG_CACHE_TTL: {{ .Values.settings.app.cacheTTL | quote }}

0 commit comments

Comments
 (0)