Skip to content

Commit

Permalink
fix(agent): adding option to define env vars to the agent
Browse files Browse the repository at this point in the history
  • Loading branch information
danielbdias committed Sep 30, 2024
1 parent de7a7c7 commit fec3a11
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 5 deletions.
11 changes: 7 additions & 4 deletions charts/tracetest-agent/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -40,17 +40,20 @@ spec:
{{- if .Values.agent.skipVerify }}
"--skip-verify",
{{- end}}

"--mode",
"verbose"
]
resources:
{{- toYaml .Values.resources | nindent 12 }}
{{- if .Values.agent.apiKey }}
env:
- name: TRACETEST_MODE
value: "verbose"
{{- if .Values.agent.apiKey }}
- name: TRACETEST_API_KEY
valueFrom:
secretKeyRef:
name: {{ include "tracetest-agent.fullname" . }}-secret
key: apiKey
{{- end }}
{{- range $key, $value := .env }}
- name: {{ $key }}
value: "{{ $value }}"
{{- end }}
4 changes: 3 additions & 1 deletion charts/tracetest-agent/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,6 @@ agent:
serverURL: "https://app.tracetest.io"
skipVerify: false

resources: {}
resources: {}

env: {}

0 comments on commit fec3a11

Please sign in to comment.