Skip to content

Commit

Permalink
fix: wrong references of helm values in the prometheus template (chao…
Browse files Browse the repository at this point in the history
…s-mesh#4543)

Signed-off-by: boxker <[email protected]>
Co-authored-by: Yue Yang <[email protected]>
  • Loading branch information
boxker and g1eny0ung authored Dec 7, 2024
1 parent 3c631bc commit cb35037
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 6 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ For more information and how-to, see [RFC: Keep A Changelog](https://github.com/
### Fixed

- Issue with getting a single archive in the Dashboard UI [#4521](https://github.com/chaos-mesh/chaos-mesh/pull/4521)
- Wrong references of helm values in the prometheus template [#4543](https://github.com/chaos-mesh/chaos-mesh/pull/4543)

### Security

Expand Down
12 changes: 6 additions & 6 deletions helm/chaos-mesh/templates/prometheus-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ spec:
{{- end }}
initContainers:
- name: data-permission-fix
image: busybox
image: {{ .Values.prometheus.busybox.image }}
command: ["/bin/chmod","-R","777", "/data"]
volumeMounts:
- name: data
Expand All @@ -56,9 +56,9 @@ spec:
- name: prometheus
image: {{ .Values.prometheus.image }}
imagePullPolicy: {{ .Values.prometheus.imagePullPolicy | default "IfNotPresent" }}
{{- if .Values.chaosDaemon.resources }}
{{- if .Values.prometheus.resources }}
resources:
{{ toYaml .Values.chaosDaemon.resources | indent 12 }}
{{ toYaml .Values.prometheus.resources | indent 12 }}
{{- end }}
args:
- --storage.tsdb.path=/data
Expand Down Expand Up @@ -88,15 +88,15 @@ spec:
- configMap:
name: prometheus-config
name: prometheus-config
{{- with .Values.controllerManager.nodeSelector }}
{{- with .Values.prometheus.nodeSelector }}
nodeSelector:
{{ toYaml . | indent 8 }}
{{- end }}
{{- with .Values.controllerManager.affinity }}
{{- with .Values.prometheus.affinity }}
affinity:
{{ toYaml . | indent 8 }}
{{- end }}
{{- with .Values.controllerManager.tolerations }}
{{- with .Values.prometheus.tolerations }}
tolerations:
{{ toYaml . | indent 8 }}
{{- end }}
Expand Down
8 changes: 8 additions & 0 deletions helm/chaos-mesh/values.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -744,6 +744,14 @@
"properties": {},
"type": "object"
},
"busybox": {
"properties": {
"image": {
"type": "string"
}
},
"type": "object"
},
"create": {
"type": "boolean"
},
Expand Down
3 changes: 3 additions & 0 deletions helm/chaos-mesh/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -494,6 +494,9 @@ prometheus:
serviceAccount: prometheus
# Docker image for prometheus
image: prom/prometheus:v2.18.1
# Docker image for busybox
busybox:
image: busybox
# Image pull policy
imagePullPolicy: IfNotPresent
# Custom priorityClassName for using pod priorities
Expand Down

0 comments on commit cb35037

Please sign in to comment.