4 name: {{ template "influxdb.fullname" . }}
6 {{- include "influxdb.labels" . | nindent 4 }}
11 {{- include "influxdb.selectorLabels" . | nindent 6 }}
12 serviceName: "{{ include "influxdb.fullname" . }}"
16 {{- include "influxdb.selectorLabels" . | nindent 8 }}
17 {{- if .Values.podLabels }}
18 {{ toYaml .Values.podLabels | indent 8 }}
20 {{- if .Values.podAnnotations }}
22 {{ toYaml .Values.podAnnotations | indent 8 }}
27 {{- if .Values.persistence.enabled }}
28 {{- if not (empty .Values.persistence.name) }}
29 persistentVolumeClaim:
30 claimName: {{ .Values.persistence.name }}
32 persistentVolumeClaim:
33 claimName: {{ template "influxdb.fullname" . }}
38 {{- if .Values.initScripts.enabled }}
41 name: {{ include "influxdb.fullname" . }}-init
44 {{- if .Values.volumes }}
45 {{- toYaml .Values.volumes | nindent 8 }}
47 serviceAccountName: {{ include "influxdb.serviceAccountName" . }}
49 - name: {{ .Chart.Name }}
50 image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
51 imagePullPolicy: {{ .Values.image.pullPolicy }}
53 - name: {{ .Values.service.portName }}
57 # Automated setup will not run if an existing boltdb file is found at the configured path.
58 # This behavior allows for the InfluxDB container to reboot post-setup without encountering "DB is already set up" errors.
59 - name: DOCKER_INFLUXDB_INIT_MODE
61 # The username to set for the system's initial super-user (Required).
62 - name: DOCKER_INFLUXDB_INIT_USERNAME
63 value: {{ .Values.adminUser.user }}
64 # The password to set for the system's inital super-user (Required).
65 - name: DOCKER_INFLUXDB_INIT_PASSWORD
68 {{- if .Values.adminUser.existingSecret }}
69 name: {{ .Values.adminUser.existingSecret -}}
71 name: {{ template "influxdb.fullname" . }}-auth
74 # The name to set for the system's initial organization (Required).
75 - name: DOCKER_INFLUXDB_INIT_ORG
76 value: {{ .Values.adminUser.organization }}
77 # The name to set for the system's initial bucket (Required).
78 - name: DOCKER_INFLUXDB_INIT_BUCKET
79 value: {{ .Values.adminUser.bucket }}
80 # The duration the system's initial bucket should retain data. If not set, the initial bucket will retain data forever.
81 - name: DOCKER_INFLUXDB_INIT_RETENTION
82 value: {{ .Values.adminUser.retention_policy }}
83 # The authentication token to associate with the system's initial super-user. If not set, a token will be auto-generated by the system.
84 - name: DOCKER_INFLUXDB_INIT_ADMIN_TOKEN
87 {{- if .Values.adminUser.existingSecret }}
88 name: {{ .Values.adminUser.existingSecret -}}
90 name: {{ template "influxdb.fullname" . }}-auth
93 # Path to the BoltDB database.
94 - name: INFLUXD_BOLT_PATH
95 value: {{ .Values.persistence.mountPath }}/influxd.bolt
96 # Path to persistent storage engine files where InfluxDB stores all Time-Structure Merge Tree (TSM) data on disk.
97 - name: INFLUXD_ENGINE_PATH
98 value: {{ .Values.persistence.mountPath }}
99 {{- with .Values.env }}
100 # Extra environment variables from .Values.env
101 {{- toYaml . | nindent 12 }}
103 {{- if .Values.securityContext }}
105 {{- toYaml .Values.securityContext | nindent 12 }}
109 path: {{ .Values.livenessProbe.path | default "/health" }}
111 scheme: {{ .Values.livenessProbe.scheme | default "HTTP" }}
112 initialDelaySeconds: {{ .Values.livenessProbe.initialDelaySeconds | default 0 }}
113 periodSeconds: {{ .Values.livenessProbe.periodSeconds | default 10 }}
114 timeoutSeconds: {{ .Values.livenessProbe.timeoutSeconds | default 1 }}
115 failureThreshold: {{ .Values.livenessProbe.failureThreshold | default 3 }}
118 path: {{ .Values.readinessProbe.path | default "/health" }}
120 scheme: {{ .Values.readinessProbe.scheme | default "HTTP" }}
121 initialDelaySeconds: {{ .Values.readinessProbe.initialDelaySeconds | default 0 }}
122 periodSeconds: {{ .Values.readinessProbe.periodSeconds | default 10 }}
123 timeoutSeconds: {{ .Values.readinessProbe.timeoutSeconds | default 1 }}
124 successThreshold: {{ .Values.readinessProbe.successThreshold | default 1 }}
125 failureThreshold: {{ .Values.readinessProbe.failureThreshold | default 3 }}
126 {{- if .Values.startupProbe.enabled }}
129 path: {{ .Values.startupProbe.path | default "/health" }}
131 scheme: {{ .Values.startupProbe.scheme | default "HTTP" }}
132 initialDelaySeconds: {{ .Values.startupProbe.initialDelaySeconds | default 30 }}
133 periodSeconds: {{ .Values.startupProbe.periodSeconds | default 5 }}
134 timeoutSeconds: {{ .Values.startupProbe.timeoutSeconds | default 1 }}
135 failureThreshold: {{ .Values.startupProbe.failureThreshold | default 6 }}
139 mountPath: {{ .Values.persistence.mountPath }}
140 subPath: {{ .Values.persistence.subPath }}
141 {{- if .Values.initScripts.enabled }}
143 mountPath: /docker-entrypoint-initdb.d
145 {{- if .Values.mountPoints }}
146 {{- toYaml .Values.mountPoints | nindent 10 }}
149 {{ .Values.resources | toYaml | nindent 12 | trim }}
151 {{- if .Values.securityContext.runAsGroup }}
153 fsGroup: {{ .Values.securityContext.runAsGroup }}
155 {{- with .Values.nodeSelector }}
157 {{ toYaml . | nindent 8 | trim }}
160 {{- with .Values.affinity }}
162 {{ toYaml . | nindent 8 | trim }}
165 {{- with .Values.tolerations }}
167 {{ toYaml . | nindent 8 | trim }}