Skip to content

Commit

Permalink
fix: correct the way of handling env for configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
1995parham committed Oct 23, 2024
1 parent 67ab438 commit 3a8ab67
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion charts/soteria/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ spec:
- name: TZ
value: {{ .Values.timezone }}
{{ if .Values.tracing.useDaemonset }}
- name: SOTERIA_TRACER__ENDPOINT
- name: soteria_tracer__endpoint
value: $(JAEGER_AGENT_HOST):4317
- name: JAEGER_AGENT_HOST
valueFrom:
Expand Down
2 changes: 1 addition & 1 deletion internal/config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ func New() Config {
// load environment variables
if err := k.Load(env.Provider(Prefix, ".", func(s string) string {
return strings.ReplaceAll(strings.ToLower(
strings.TrimPrefix(s, Prefix)), "_", ".")
strings.TrimPrefix(s, Prefix)), "__", ".")
}), nil); err != nil {
log.Printf("error loading environment variables: %s", err)
}
Expand Down

0 comments on commit 3a8ab67

Please sign in to comment.