fix(helm): set OIDC client env vars when using existingSecret
The deployment template only checked for clientId being set in values.yaml, so when using existingSecret without setting clientId, the NEXTCLOUD_OIDC_CLIENT_ID and NEXTCLOUD_OIDC_CLIENT_SECRET env vars were never created. This broke existingSecret for OIDC-based auth - the server would always fall back to DCR even when pre-registered credentials were provided via secret. Fix: Check for EITHER clientId OR existingSecret being set before creating the OIDC client credential env vars. Affects both OIDC-based auth modes: - auth.oauth.existingSecret (OAuth mode) - auth.multiUserBasic.existingSecret (multi-user BasicAuth with offline access) 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -100,7 +100,7 @@ spec:
|
||||
key: {{ .Values.auth.multiUserBasic.tokenEncryptionKeyKey }}
|
||||
- name: NEXTCLOUD_OIDC_SCOPES
|
||||
value: {{ .Values.auth.multiUserBasic.scopes | quote }}
|
||||
{{- if .Values.auth.multiUserBasic.clientId }}
|
||||
{{- if or .Values.auth.multiUserBasic.clientId .Values.auth.multiUserBasic.existingSecret }}
|
||||
# Static OAuth credentials (optional - uses DCR if not provided)
|
||||
- name: NEXTCLOUD_OIDC_CLIENT_ID
|
||||
valueFrom:
|
||||
@@ -122,7 +122,7 @@ spec:
|
||||
value: {{ include "nextcloud-mcp-server.publicIssuerUrl" . | quote }}
|
||||
- name: NEXTCLOUD_OIDC_SCOPES
|
||||
value: {{ .Values.auth.oauth.scopes | quote }}
|
||||
{{- if .Values.auth.oauth.clientId }}
|
||||
{{- if or .Values.auth.oauth.clientId .Values.auth.oauth.existingSecret }}
|
||||
- name: NEXTCLOUD_OIDC_CLIENT_ID
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
|
||||
Reference in New Issue
Block a user