Skip to content

Commit

Permalink
Support containerSecurityContext
Browse files Browse the repository at this point in the history
  • Loading branch information
PaulFarver committed Sep 4, 2023
1 parent 65564b1 commit f078717
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 1 deletion.
2 changes: 1 addition & 1 deletion charts/influxdb/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
apiVersion: v1
name: influxdb
version: 4.12.5
version: 4.13.0
appVersion: 1.8.10
description: Scalable datastore for metrics, events, and real-time analytics.
keywords:
Expand Down
1 change: 1 addition & 0 deletions charts/influxdb/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,7 @@ The following table lists configurable parameters, their descriptions, and their
| affinity | [Affinity](https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity) for pod assignment | { |
| tolerations | [Tolerations](https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/) for pod assignment | [] |
| securityContext | [securityContext](https://kubernetes.io/docs/tasks/configure-pod-container/security-context/) for pod | {} |
| containerSecurityContext | [containerSecurityContext](https://kubernetes.io/docs/tasks/configure-pod-container/security-context/) for container | {} |
| env | environment variables for influxdb container | {} |
| volumes | `volumes` stanza(s) to be used in the main container | nil |
| mountPoints | `volumeMount` stanza(s) to be used in the main container | nil |
Expand Down
3 changes: 3 additions & 0 deletions charts/influxdb/templates/statefulset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,9 @@ spec:
failureThreshold: {{ .Values.startupProbe.failureThreshold | default 6 }}
periodSeconds: {{ .Values.startupProbe.periodSeconds | default 5 }}
{{- end }}
{{- with .Values.containerSecurityContext }}
securityContext: {{ toYaml . | nindent 10 }}
{{- end }}
volumeMounts:
- name: {{ include "influxdb.fullname" . }}-data
mountPath: /var/lib/influxdb
Expand Down
3 changes: 3 additions & 0 deletions charts/influxdb/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,9 @@ securityContext: {}
# runAsUser: 999
# runAsGroup: 999

containerSecurityContext: {}
# readOnlyRootFilesystem: true

startupProbe:
enabled: false
# path: "/ping"
Expand Down

0 comments on commit f078717

Please sign in to comment.