Repository navigation
feat: add oidcProxy support to Helm chart #560
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -74,6 +74,50 @@ spec: | |
| {{- if .Values.forecastle.openshiftOauthProxy.resources }} | ||
| resources: | ||
| {{ toYaml .Values.forecastle.openshiftOauthProxy.resources | indent 10 }} | ||
| {{- end }} | ||
| {{- end }} | ||
| {{- if .Values.forecastle.oidcProxy.enabled }} | ||
| {{- if .Values.forecastle.openshiftOauthProxy.enabled }} | ||
| {{- fail "openshiftOauthProxy and oidcProxy cannot both be enabled" }} | ||
| {{- end }} | ||
| - name: oidc-proxy | ||
| image: {{ required "oidcProxy.image is required when oidcProxy is enabled" .Values.forecastle.oidcProxy.image | quote }} | ||
| imagePullPolicy: IfNotPresent | ||
| ports: | ||
| - containerPort: 8443 | ||
| name: public | ||
| args: | ||
| - --https-address=:8443 | ||
| - --provider=oidc | ||
| - --oidc-issuer-url={{ required "oidcProxy.issuerUrl is required" .Values.forecastle.oidcProxy.issuerUrl }} | ||
| - --client-id={{ required "oidcProxy.clientId is required" .Values.forecastle.oidcProxy.clientId }} | ||
| - --redirect-url={{ required "oidcProxy.redirectUrl is required" .Values.forecastle.oidcProxy.redirectUrl }} | ||
| - --upstream=http://localhost:3000 | ||
| - --tls-cert=/etc/tls/private/tls.crt | ||
| - --tls-key=/etc/tls/private/tls.key | ||
| - --email-domain=* | ||
| - --scope={{ .Values.forecastle.oidcProxy.scopes }} | ||
|
Comment on lines
+79
to
+99
|
||
| env: | ||
| - name: OAUTH2_PROXY_CLIENT_SECRET | ||
| valueFrom: | ||
| secretKeyRef: | ||
| name: {{ required "oidcProxy.clientSecretRef.name is required" .Values.forecastle.oidcProxy.clientSecretRef.name }} | ||
| key: {{ required "oidcProxy.clientSecretRef.key is required" .Values.forecastle.oidcProxy.clientSecretRef.key }} | ||
| - name: OAUTH2_PROXY_COOKIE_SECRET | ||
| valueFrom: | ||
| secretKeyRef: | ||
| name: {{ required "oidcProxy.cookieSecretRef.name is required" .Values.forecastle.oidcProxy.cookieSecretRef.name }} | ||
| key: {{ required "oidcProxy.cookieSecretRef.key is required" .Values.forecastle.oidcProxy.cookieSecretRef.key }} | ||
| volumeMounts: | ||
| - mountPath: /etc/tls/private | ||
| name: oauth-proxy-tls | ||
| {{- with .Values.forecastle.oidcProxy.securityContext }} | ||
| securityContext: | ||
| {{- toYaml . | nindent 10 }} | ||
| {{- end }} | ||
| {{- if .Values.forecastle.oidcProxy.resources }} | ||
| resources: | ||
| {{ toYaml .Values.forecastle.oidcProxy.resources | indent 10 }} | ||
| {{- end }} | ||
| {{- end }} | ||
|
Comment on lines
+79
to
122
|
||
| volumes: | ||
|
|
@@ -85,6 +129,11 @@ spec: | |
| secret: | ||
| secretName: openshift-oauth-proxy-tls | ||
| {{- end }} | ||
| {{- if .Values.forecastle.oidcProxy.enabled }} | ||
| - name: oauth-proxy-tls | ||
| secret: | ||
| secretName: oauth-proxy-tls | ||
| {{- end }} | ||
| serviceAccountName: {{ template "forecastle.name" . }} | ||
| {{- with .Values.forecastle.deployment.podSecurityContext }} | ||
| securityContext: | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -2,7 +2,7 @@ forecastle: | |
| labels: | ||
| group: com.stakater.platform | ||
| provider: stakater | ||
| version: 1.2.0 | ||
| version: 1.3.0 | ||
| namespace: default | ||
| image: | ||
| name: stakater/forecastle | ||
|
|
@@ -100,6 +100,21 @@ forecastle: | |
| # memory: 64Mi | ||
| # image: stakater/oauth-proxy:v0.0.2 | ||
| securityContext: {} | ||
| oidcProxy: | ||
| enabled: false | ||
| image: "" | ||
| issuerUrl: "" | ||
| clientId: "" | ||
| redirectUrl: "" | ||
| scopes: "openid email profile" | ||
| clientSecretRef: | ||
| name: "" | ||
| key: "" | ||
| cookieSecretRef: | ||
| name: "" | ||
| key: "" | ||
|
Comment on lines
+103
to
+115
|
||
| resources: {} | ||
| securityContext: {} | ||
| service: | ||
| annotations: {} | ||
| expose: "false" | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Chart version is bumped to 1.3.0, but
values.yamlstill setsforecastle.labels.version: 1.2.0(used in_helpers.tplfor resource labels). This will make labels inconsistent with the chart release version. Consider updating the default label value to 1.3.0 or deriving it from.Chart.Versionto avoid manual drift.