diff --git a/charts/clearml-agent/templates/agentk8sglue-deployment.yaml b/charts/clearml-agent/templates/agentk8sglue-deployment.yaml index 2dcdd01..713348d 100644 --- a/charts/clearml-agent/templates/agentk8sglue-deployment.yaml +++ b/charts/clearml-agent/templates/agentk8sglue-deployment.yaml @@ -112,12 +112,20 @@ spec: - name: CLEARML_API_ACCESS_KEY valueFrom: secretKeyRef: + {{- if .Values.clearml.existingAgentk8sglueSecret }} + name: {{ .Values.clearml.existingAgentk8sglueSecret }} + {{- else }} name: {{ include "clearmlAgent.fullname" . }}-ac + {{- end }} key: agentk8sglue_key - name: CLEARML_API_SECRET_KEY valueFrom: secretKeyRef: + {{- if .Values.clearml.existingAgentk8sglueSecret }} + name: {{ .Values.clearml.existingAgentk8sglueSecret }} + {{- else }} name: {{ include "clearmlAgent.fullname" . }}-ac + {{- end }} key: agentk8sglue_secret - name: CLEARML_WORKER_ID value: {{ include "clearmlAgent.fullname" . }}