Skip to content

Commit

Permalink
secret mlfllow add 2 variables in library chart to be discovered (#108)
Browse files Browse the repository at this point in the history
adding username and password in the discoverable mechanism for mlflow
  • Loading branch information
JackLemaitre authored Nov 23, 2023
1 parent 77484db commit 3060178
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 2 deletions.
2 changes: 1 addition & 1 deletion charts/library-chart/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
apiVersion: v2
name: library-chart
version: 1.5.16
version: 1.5.17
type: library
2 changes: 1 addition & 1 deletion charts/library-chart/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# library-chart

![Version: 1.5.16](https://img.shields.io/badge/Version-1.5.16-informational?style=flat-square) ![Type: library](https://img.shields.io/badge/Type-library-informational?style=flat-square)
![Version: 1.5.17](https://img.shields.io/badge/Version-1.5.17-informational?style=flat-square) ![Type: library](https://img.shields.io/badge/Type-library-informational?style=flat-square)

----------------------------------------------
Autogenerated from chart metadata using [helm-docs v1.11.0](https://github.com/norwoodj/helm-docs/releases/v1.11.0)
9 changes: 9 additions & 0 deletions charts/library-chart/templates/_secret.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -119,15 +119,24 @@ stringData:
{{- if (index $secret "metadata" "annotations") -}}
{{- if and (index $secret "metadata" "annotations" "onyxia/discovery") (eq "mlflow" (index $secret "metadata" "annotations" "onyxia/discovery" | toString)) -}}
{{- $uri:= ( index $secret.data "uri" | default "") | b64dec -}}
{{- $mlflow_tracking_username:= ( index $secret.data "MLFLOW_TRACKING_USERNAME" | default "") | b64dec -}}
{{- $mlflow_tracking_password:= ( index $secret.data "MLFLOW_TRACKING_PASSWORD" | default "") | b64dec -}}

apiVersion: v1
kind: Secret
metadata:
name: {{ include "library-chart.secretNameMLFlow" $context }}
labels:
{{- include "library-chart.labels" $context | nindent 4 }}
stringData:
{{- if $uri }}
MLFLOW_TRACKING_URI: {{ printf "%s" $uri }}
{{- end }}
{{- if and $mlflow_tracking_username $mlflow_tracking_password }}
MLFLOW_TRACKING_USERNAME: {{ printf "%s" $mlflow_tracking_username }}
MLFLOW_TRACKING_PASSWORD: {{ printf "%s" $mlflow_tracking_password }}
{{- end }}
{{- end }}
{{- end }}
{{- end }}
{{- end }}
Expand Down

0 comments on commit 3060178

Please sign in to comment.