Skip to content

Commit

Permalink
use extraEnv
Browse files Browse the repository at this point in the history
  • Loading branch information
TheoBrigitte committed Aug 19, 2024
1 parent cc15b0c commit 7556849
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 11 deletions.
2 changes: 0 additions & 2 deletions pkg/monitoring/alloy/configmap.go
Original file line number Diff line number Diff line change
Expand Up @@ -83,14 +83,12 @@ func (a *Service) GenerateAlloyMonitoringConfigMapData(ctx context.Context, curr
Replicas int
RequestsCPU string
RequestsMemory string
SecretName string
}{
AlloyConfig: alloyConfig,
PriorityClassName: commonmonitoring.PriorityClassName,
Replicas: shards,
RequestsCPU: commonmonitoring.AlloyRequestsCPU,
RequestsMemory: commonmonitoring.AlloyRequestsMemory,
SecretName: commonmonitoring.AlloyMonitoringAgentAppName,
}

var values bytes.Buffer
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,6 @@ alloy:
create: true
content: |-
{{ .AlloyConfig | indent 8 }}
envFrom:
- secretRef:
name: {{ .SecretName }}
resources:
requests:
cpu: {{ .RequestsCPU }}
Expand Down
10 changes: 4 additions & 6 deletions pkg/monitoring/alloy/templates/monitoring-secret.yaml.template
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
alloy:
alloy:
secret:
create: true
content: |-
{{- range . }}
{{ .Name | indent 8 }}: {{ .Value }}
{{- end }}
extraEnv:
{{- range . }}
- {{ .Name }}={{ .Value }}
{{- end }}

0 comments on commit 7556849

Please sign in to comment.