Skip to content
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

feat/fix(dhcore): added token exchange support, keystore, modified en… #103

Merged
merged 1 commit into from
Aug 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions charts/core/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ apiVersion: v2
name: core
description: Core backend application for DigitalHub.
type: application
version: 0.1.37
appVersion: "0.6.0"
version: 0.1.38
appVersion: "0.7.0-beta1"
maintainers:
- name: ffais
url: https://github.com/ffais
Expand Down
6 changes: 6 additions & 0 deletions charts/core/templates/configmap.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -56,3 +56,9 @@ data:
DOCKER_REGISTRY_SECRET: {{ .Values.global.registry.secretName }}
{{- end }}
DH_CORS_ORIGINS: {{ .Values.corsOrigin | quote }}
{{- if .Values.keystore.secretName }}
JWT_KEYSTORE_PATH: "/etc/keystore/{{ .Values.keystore.keyName }}"
JWT_KEYSTORE_KID: {{ .Values.keystore.keystoreKid }}
{{- end }}
AWS_DEFAULT_REGION: {{ .Values.minio.awsDefaultRegion }}
AWS_REGION: {{ .Values.minio.awsRegion }}
48 changes: 24 additions & 24 deletions charts/core/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -48,36 +48,16 @@ spec:
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}"
imagePullPolicy: {{ .Values.image.pullPolicy }}
env:
- name: DH_S3_ACCESS_KEY_ID
- name: AWS_ACCESS_KEY
valueFrom:
secretKeyRef:
name: {{ .Values.global.minio.digitalhubUserSecret }}
key: digitalhubUser
- name: DH_S3_SECRET_ACCESS_KEY
- name: AWS_SECRET_KEY
valueFrom:
secretKeyRef:
name: {{ .Values.global.minio.digitalhubUserSecret }}
key: digitalhubPassword
- name: DH_AWS_ACCESS_KEY_ID
valueFrom:
secretKeyRef:
name: {{ .Values.global.minio.digitalhubUserSecret }}
key: digitalhubUser
- name: DH_AWS_SECRET_ACCESS_KEY
valueFrom:
secretKeyRef:
name: {{ .Values.global.minio.digitalhubUserSecret }}
key: digitalhubPassword
- name: DH_POSTGRES_USER
valueFrom:
secretKeyRef:
name: digitalhub-owner-user.database-postgres-cluster.credentials.postgresql.acid.zalan.do
key: username
- name: DH_POSTGRES_PASSWORD
valueFrom:
secretKeyRef:
name: digitalhub-owner-user.database-postgres-cluster.credentials.postgresql.acid.zalan.do
key: password
- name: JDBC_USER
valueFrom:
secretKeyRef:
Expand Down Expand Up @@ -111,6 +91,16 @@ spec:
value: {{ .Values.authentication.openId.oidcClientId }}
{{- end }}
{{- end }}
- name: JWT_CLIENT_ID
valueFrom:
secretKeyRef:
name: core-auth-creds
key: clientId
- name: JWT_CLIENT_SECRET
valueFrom:
secretKeyRef:
name: core-auth-creds
key: clientSecret
envFrom:
- configMapRef:
name: {{ include "core.fullname" . }}
Expand All @@ -120,12 +110,22 @@ spec:
protocol: TCP
resources:
{{- toYaml .Values.resources | nindent 12 }}
{{- with .Values.volumeMounts }}
volumeMounts:
{{- if .Values.keystore.secretName }}
- name: keystore
mountPath: "/etc/keystore/{{ .Values.keystore.keyName }}"
subPath: {{ .Values.keystore.keyName }}
{{- end }}
{{- with .Values.volumeMounts }}
{{- toYaml . | nindent 12 }}
{{- end }}
{{- with .Values.volumes }}
volumes:
{{- if .Values.keystore.secretName }}
- name: keystore
secret:
secretName: {{ .Values.keystore.secretName }}
{{- end }}
{{- with .Values.volumes }}
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.nodeSelector }}
Expand Down
15 changes: 14 additions & 1 deletion charts/core/templates/secret.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,17 @@ metadata:
type: Opaque
data:
username: {{ .Values.events.rabbitmq.credentials.username | b64enc | quote }}
password: {{ .Values.events.rabbitmq.credentials.password | b64enc | quote }}
password: {{ .Values.events.rabbitmq.credentials.password | b64enc | quote }}
---
apiVersion: v1
kind: Secret
metadata:
name: core-auth-creds
annotations:
"helm.sh/hook": pre-install
"helm.sh/hook-weight": "-4"
"helm.sh/hook-delete-policy": hook-failed
type: Opaque
data:
clientId: {{ randAlphaNum 24 | nospace | b64enc }}
clientSecret: {{ randAlphaNum 24 | nospace | b64enc }}
17 changes: 12 additions & 5 deletions charts/core/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,8 @@ minio:
endpointPort: "9000"
bucket: "mlrun"
protocol: "http"
awsDefaultRegion: ""
awsRegion: ""

service:
port: "8080"
Expand Down Expand Up @@ -147,15 +149,15 @@ runtime:
tag: "0.6.1"
dbt:
image: "ghcr.io/scc-digitalhub/digitalhub-sdk/wrapper-dbt"
tag: "0.6.1"
tag: "0.7.0b0"
kfp:
image: "ghcr.io/scc-digitalhub/digitalhub-sdk/wrapper-kfp"
tag: "0.6.1"
tag: "0.7.0b0"
python:
image: "ghcr.io/scc-digitalhub/digitalhub-serverless/python-runtime"
tag3_9: "3.9-0.6.1"
tag3_10: "3.10-0.6.1"
tag3_11: "3.11-0.6.1"
tag3_9: "3.9-0.7.0b0"
tag3_10: "3.10-0.7.0b0"
tag3_11: "3.11-0.7.0b0"

authentication:
basic:
Expand Down Expand Up @@ -205,3 +207,8 @@ corsOrigin: ""
registry:
kaniko:
imagePrefix: ""

keystore:
secretName: ""
keyName: ""
keystoreKid: ""