Issue-ID: RICAPP-169 - Inclusion of InfluxDB helm chart for KPIMON, AD, TS, QP xApps
updated 3rdparty influxdb templates to refer the definitions from the common template
updated supporting files in the ric-dep repo
Signed-off-by: Chandrasekaran Ramachandran <chandrasekaran-r@hcl.com>
Change-Id: If5b2fc8cb7b62a071788ccc045e6dcf36fa76490
diff --git a/RECIPE_EXAMPLE/example_recipe.yaml b/RECIPE_EXAMPLE/example_recipe.yaml
index 2e75b49..23c7037 100644
--- a/RECIPE_EXAMPLE/example_recipe.yaml
+++ b/RECIPE_EXAMPLE/example_recipe.yaml
@@ -1,5 +1,6 @@
################################################################################
# Copyright (c) 2019 AT&T Intellectual Property. #
+# Copyright (c) 2021 HCL Technologies Limited. #
# #
# Licensed under the Apache License, Version 2.0 (the "License"); #
# you may not use this file except in compliance with the License. #
@@ -184,3 +185,9 @@
registry: "nexus3.o-ran-sc.org:10002/o-ran-sc"
name: ric-plt-alarmmanager
tag: 0.5.9
+
+influxdb:
+ image:
+ registry: "influxdb"
+ name: influxdb
+ tag: "1.8.0-alpine"
diff --git a/bin/install b/bin/install
index 6f4fbd4..d879a03 100755
--- a/bin/install
+++ b/bin/install
@@ -2,6 +2,7 @@
################################################################################
# Copyright (c) 2019 AT&T Intellectual Property. #
# Copyright (c) 2019 Nokia. #
+# Copyright (c) 2021 HCL Technologies Limited. #
# #
# Licensed under the Apache License, Version 2.0 (the "License"); #
# you may not use this file except in compliance with the License. #
@@ -119,7 +120,7 @@
LOCAL_REPOSITORY=$(echo "$COMMON_BLOCK" | awk '/^ *localregistry:/{print $2}')
# replace the dbaasha with dbaas1 if deploying non HA DBaaS
-COMPONENTS=${LIST_OF_COMPONENTS:-"infrastructure dbaas xapp-onboarder appmgr rtmgr e2mgr e2term a1mediator submgr vespamgr jaegeradapter o1mediator alarmmanager"}
+COMPONENTS=${LIST_OF_COMPONENTS:-"infrastructure dbaas xapp-onboarder appmgr rtmgr e2mgr e2term a1mediator submgr vespamgr jaegeradapter o1mediator alarmmanager influxdb"}
echo "Deploying RIC infra components [$COMPONENTS]"
diff --git a/bin/uninstall b/bin/uninstall
index 2fb080e..f065fe8 100755
--- a/bin/uninstall
+++ b/bin/uninstall
@@ -2,6 +2,7 @@
################################################################################
# Copyright (c) 2019 AT&T Intellectual Property. #
# Copyright (c) 2019 Nokia. #
+# Copyright (c) 2021 HCL Technologies Limited. #
# #
# Licensed under the Apache License, Version 2.0 (the "License"); #
# you may not use this file except in compliance with the License. #
@@ -16,7 +17,7 @@
# limitations under the License. #
################################################################################
-COMPONENTS="xapp-onboarder appmgr rtmgr e2mgr e2term a1mediator submgr vespamgr jaegeradapter dbaas infrastructure o1mediator alarmmanager"
+COMPONENTS="xapp-onboarder appmgr rtmgr e2mgr e2term a1mediator submgr vespamgr jaegeradapter dbaas infrastructure o1mediator alarmmanager influxdb"
RECIPE_NAMESPACE=$(kubectl get cm --all-namespaces | grep ricplt-recipe | awk '{print $1}')
kubectl get configmap -n $RECIPE_NAMESPACE ricplt-recipe -o jsonpath='{.data.recipe}' > /tmp/recipe.yaml
diff --git a/helm/3rdparty/influxdb/requirements.yaml b/helm/3rdparty/influxdb/requirements.yaml
new file mode 100644
index 0000000..b5b89b7
--- /dev/null
+++ b/helm/3rdparty/influxdb/requirements.yaml
@@ -0,0 +1,20 @@
+################################################################################
+# Copyright (c) 2021 HCL Technologies Limited. #
+# #
+# Licensed under the Apache License, Version 2.0 (the "License"); #
+# you may not use this file except in compliance with the License. #
+# You may obtain a copy of the License at #
+# #
+# http://www.apache.org/licenses/LICENSE-2.0 #
+# #
+# Unless required by applicable law or agreed to in writing, software #
+# distributed under the License is distributed on an "AS IS" BASIS, #
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. #
+# See the License for the specific language governing permissions and #
+# limitations under the License. #
+################################################################################
+
+dependencies:
+ - name: ric-common
+ version: ^3.1.0
+ repository: "@local"
diff --git a/helm/3rdparty/influxdb/templates/NOTES.txt b/helm/3rdparty/influxdb/templates/NOTES.txt
index 41ffa05..4da270f 100644
--- a/helm/3rdparty/influxdb/templates/NOTES.txt
+++ b/helm/3rdparty/influxdb/templates/NOTES.txt
@@ -1,18 +1,33 @@
-InfluxDB can be accessed via port {{ .Values.config.http.bind_address | default 8086 }} on the following DNS name from within your cluster:
+################################################################################
+# Copyright (c) 2021 HCL Technolgies Limited. #
+# #
+# Licensed under the Apache License, Version 2.0 (the "License"); #
+# you may not use this file except in compliance with the License. #
+# You may obtain a copy of the License at #
+# #
+# http://www.apache.org/licenses/LICENSE-2.0 #
+# #
+# Unless required by applicable law or agreed to in writing, software #
+# distributed under the License is distributed on an "AS IS" BASIS, #
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. #
+# See the License for the specific language governing permissions and #
+# limitations under the License. #
+################################################################################
+InfluxDB can be accessed via port {{ include "common.serviceport.influxdb.http.bind_address" . | default 8086 }} on the following DNS name from within your cluster:
- http://{{ include "influxdb.fullname" . }}.{{ .Release.Namespace }}:{{ .Values.config.http.bind_address | default 8086 }}
+ http://{{ include "common.fullname.influxdb" . }}.{{ .Release.Namespace }}:{{ include "common.serviceport.influxdb.http.bind_address" . | default 8086 }}
You can connect to the remote instance with the influx CLI. To forward the API port to localhost:8086, run the following:
- kubectl port-forward --namespace {{ .Release.Namespace }} $(kubectl get pods --namespace {{ .Release.Namespace }} -l app={{ include "influxdb.fullname" . }} -o jsonpath='{ .items[0].metadata.name }') 8086:{{ .Values.config.http.bind_address | default 8086 }}
+ kubectl port-forward --namespace {{ .Release.Namespace }} $(kubectl get pods --namespace {{ .Release.Namespace }} -l app={{ include "common.fullname.influxdb" . }} -o jsonpath='{ .items[0].metadata.name }') 8086:{{ include "common.serviceport.influxdb.http.bind_address" . | default 8086 }}
You can also connect to the influx CLI from inside the container. To open a shell session in the InfluxDB pod, run the following:
- kubectl exec -i -t --namespace {{ .Release.Namespace }} $(kubectl get pods --namespace {{ .Release.Namespace }} -l app={{ include "influxdb.fullname" . }} -o jsonpath='{.items[0].metadata.name}') /bin/sh
+ kubectl exec -i -t --namespace {{ .Release.Namespace }} $(kubectl get pods --namespace {{ .Release.Namespace }} -l app={{ include "common.fullname.influxdb" . }} -o jsonpath='{.items[0].metadata.name}') /bin/sh
To view the logs for the InfluxDB pod, run the following:
- kubectl logs -f --namespace {{ .Release.Namespace }} $(kubectl get pods --namespace {{ .Release.Namespace }} -l app={{ include "influxdb.fullname" . }} -o jsonpath='{ .items[0].metadata.name }')
+ kubectl logs -f --namespace {{ .Release.Namespace }} $(kubectl get pods --namespace {{ .Release.Namespace }} -l app={{ include "common.fullname.influxdb" . }} -o jsonpath='{ .items[0].metadata.name }')
{{- if .Values.setDefaultUser.enabled }}
@@ -24,7 +39,7 @@
{{- else }}
- echo $(kubectl get secret {{ include "influxdb.fullname" . }}-auth -o "jsonpath={.data['influxdb-user']}" --namespace {{ .Release.Namespace }} | base64 --decode)
+ echo $(kubectl get secret {{ include "common.fullname.influxdb" . }}-auth -o "jsonpath={.data['influxdb-user']}" --namespace {{ .Release.Namespace }} | base64 --decode)
{{- end }}
@@ -36,7 +51,7 @@
{{- else }}
- echo $(kubectl get secret {{ include "influxdb.fullname" . }}-auth -o "jsonpath={.data['influxdb-password']}" --namespace {{ .Release.Namespace }} | base64 --decode)
+ echo $(kubectl get secret {{ include "common.fullname.influxdb" . }}-auth -o "jsonpath={.data['influxdb-password']}" --namespace {{ .Release.Namespace }} | base64 --decode)
{{- end }}
{{- end }}
diff --git a/helm/3rdparty/influxdb/templates/_helpers.tpl b/helm/3rdparty/influxdb/templates/_helpers.tpl
deleted file mode 100644
index 4866664..0000000
--- a/helm/3rdparty/influxdb/templates/_helpers.tpl
+++ /dev/null
@@ -1,63 +0,0 @@
-{{/* vim: set filetype=mustache: */}}
-{{/*
-Expand the name of the chart.
-*/}}
-{{- define "influxdb.name" -}}
-{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" -}}
-{{- end -}}
-
-{{/*
-Create a default fully qualified app name.
-We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
-If release name contains chart name it will be used as a full name.
-*/}}
-{{- define "influxdb.fullname" -}}
-{{- if .Values.fullnameOverride -}}
-{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" -}}
-{{- else -}}
-{{- $name := default .Chart.Name .Values.nameOverride -}}
-{{- if contains $name .Release.Name -}}
-{{- .Release.Name | trunc 63 | trimSuffix "-" -}}
-{{- else -}}
-{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}}
-{{- end -}}
-{{- end -}}
-{{- end -}}
-
-{{/*
-Create chart name and version as used by the chart label.
-*/}}
-{{- define "influxdb.chart" -}}
-{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" -}}
-{{- end -}}
-
-{{/*
-Common labels
-*/}}
-{{- define "influxdb.labels" -}}
-helm.sh/chart: {{ include "influxdb.chart" . }}
-{{ include "influxdb.selectorLabels" . }}
-{{- if .Chart.AppVersion }}
-app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
-{{- end }}
-app.kubernetes.io/managed-by: {{ .Release.Service }}
-{{- end -}}
-
-{{/*
-Selector labels
-*/}}
-{{- define "influxdb.selectorLabels" -}}
-app.kubernetes.io/name: {{ include "influxdb.name" . }}
-app.kubernetes.io/instance: {{ .Release.Name }}
-{{- end -}}
-
-{{/*
-Create the name of the service account to use
-*/}}
-{{- define "influxdb.serviceAccountName" -}}
-{{- if .Values.serviceAccount.create -}}
- {{ default (include "influxdb.fullname" .) .Values.serviceAccount.name }}
-{{- else -}}
- {{ default "default" .Values.serviceAccount.name }}
-{{- end -}}
-{{- end -}}
diff --git a/helm/3rdparty/influxdb/templates/backup-cronjob.yaml b/helm/3rdparty/influxdb/templates/backup-cronjob.yaml
index fed2d18..a123598 100644
--- a/helm/3rdparty/influxdb/templates/backup-cronjob.yaml
+++ b/helm/3rdparty/influxdb/templates/backup-cronjob.yaml
@@ -1,10 +1,25 @@
+################################################################################
+# Copyright (c) 2021 HCL Technolgies Limited. #
+# #
+# Licensed under the Apache License, Version 2.0 (the "License"); #
+# you may not use this file except in compliance with the License. #
+# You may obtain a copy of the License at #
+# #
+# http://www.apache.org/licenses/LICENSE-2.0 #
+# #
+# Unless required by applicable law or agreed to in writing, software #
+# distributed under the License is distributed on an "AS IS" BASIS, #
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. #
+# See the License for the specific language governing permissions and #
+# limitations under the License. #
+################################################################################
{{- if .Values.backup.enabled }}
apiVersion: batch/v1beta1
kind: CronJob
metadata:
- name: {{ include "influxdb.fullname" . }}-backup
+ name: {{ include "common.fullname.influxdb" . }}-backup
labels:
- {{- include "influxdb.labels" . | nindent 4 }}
+ {{- include "common.influxdb.labels" . | nindent 4 }}
app.kubernetes.io/component: backup
annotations:
{{- toYaml .Values.backup.annotations | nindent 4 }}
@@ -21,14 +36,14 @@
{{ toYaml .Values.backup.podAnnotations | nindent 12 }}
{{- end }}
labels:
- {{- include "influxdb.selectorLabels" . | nindent 12 }}
+ {{- include "common.influxdb.selectorLabels" . | nindent 12 }}
spec:
restartPolicy: OnFailure
volumes:
- name: backup
{{- if .Values.backup.persistence.enabled }}
persistentVolumeClaim:
- claimName: {{ include "influxdb.fullname" . }}-backup
+ claimName: {{ include "common.fullname.influxdb" . }}-backup
{{- else }}
emptyDir: {}
{{- end }}
@@ -46,7 +61,7 @@
secretName: {{ .Values.backup.s3.credentialsSecret | quote }}
{{- end }}
{{- end }}
- serviceAccountName: {{ include "influxdb.serviceAccountName" . }}
+ serviceAccountName: {{ include "common.influxdb.serviceAccountName" . }}
initContainers:
- name: influxdb-backup
image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
@@ -59,7 +74,7 @@
- '-c'
- |
influxd backup \
- -host {{ include "influxdb.fullname" . }}.{{ .Release.Namespace }}.svc:{{ .Values.config.rpc.bind_address | default 8088 }} \
+ -host {{ include "common.fullname.influxdb" . }}.{{ .Release.Namespace }}.svc:{{ include "common.serviceport.influxdb.rpc.bind_address" . | default 8088 }} \
-portable /backup/"$(date +%Y%m%d%H%M%S)"
resources:
{{- toYaml .Values.backup.resources | nindent 14 }}
diff --git a/helm/3rdparty/influxdb/templates/backup-pvc.yaml b/helm/3rdparty/influxdb/templates/backup-pvc.yaml
index ebf4ba1..a7a4db8 100644
--- a/helm/3rdparty/influxdb/templates/backup-pvc.yaml
+++ b/helm/3rdparty/influxdb/templates/backup-pvc.yaml
@@ -1,10 +1,25 @@
+################################################################################
+# Copyright (c) 2021 HCL Technolgies Limited. #
+# #
+# Licensed under the Apache License, Version 2.0 (the "License"); #
+# you may not use this file except in compliance with the License. #
+# You may obtain a copy of the License at #
+# #
+# http://www.apache.org/licenses/LICENSE-2.0 #
+# #
+# Unless required by applicable law or agreed to in writing, software #
+# distributed under the License is distributed on an "AS IS" BASIS, #
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. #
+# See the License for the specific language governing permissions and #
+# limitations under the License. #
+################################################################################
{{- if and .Values.backup.enabled .Values.backup.persistence.enabled }}
kind: PersistentVolumeClaim
apiVersion: v1
metadata:
- name: {{ include "influxdb.fullname" . }}-backup
+ name: {{ include "common.fullname.influxdb" . }}-backup
labels:
- {{- include "influxdb.labels" . | nindent 4 }}
+ {{- include "common.influxdb.labels" . | nindent 4 }}
spec:
accessModes:
- {{ .Values.backup.persistence.accessMode | quote }}
diff --git a/helm/3rdparty/influxdb/templates/backup-retention-configmap.yaml b/helm/3rdparty/influxdb/templates/backup-retention-configmap.yaml
index d158eb5..2286e10 100644
--- a/helm/3rdparty/influxdb/templates/backup-retention-configmap.yaml
+++ b/helm/3rdparty/influxdb/templates/backup-retention-configmap.yaml
@@ -1,10 +1,25 @@
+################################################################################
+# Copyright (c) 2021 HCL Technolgies Limited. #
+# #
+# Licensed under the Apache License, Version 2.0 (the "License"); #
+# you may not use this file except in compliance with the License. #
+# You may obtain a copy of the License at #
+# #
+# http://www.apache.org/licenses/LICENSE-2.0 #
+# #
+# Unless required by applicable law or agreed to in writing, software #
+# distributed under the License is distributed on an "AS IS" BASIS, #
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. #
+# See the License for the specific language governing permissions and #
+# limitations under the License. #
+################################################################################
{{- if .Values.backupRetention.enabled }}
apiVersion: v1
kind: ConfigMap
metadata:
- name: {{ include "influxdb.fullname" . }}-backup-retention
+ name: {{ include "common.fullname.influxdb" . }}-backup-retention
labels:
- {{- include "influxdb.labels" . | nindent 4 }}
+ {{- include "common.influxdb.labels" . | nindent 4 }}
data:
backup-retention.sh: |-
{{- .Files.Get "files/backup-retention-script.sh" | nindent 4 }}
diff --git a/helm/3rdparty/influxdb/templates/backup-retention-cronjob.yaml b/helm/3rdparty/influxdb/templates/backup-retention-cronjob.yaml
index 388c62d..dd63a24 100644
--- a/helm/3rdparty/influxdb/templates/backup-retention-cronjob.yaml
+++ b/helm/3rdparty/influxdb/templates/backup-retention-cronjob.yaml
@@ -1,10 +1,25 @@
+################################################################################
+# Copyright (c) 2021 HCL Technolgies Limited. #
+# #
+# Licensed under the Apache License, Version 2.0 (the "License"); #
+# you may not use this file except in compliance with the License. #
+# You may obtain a copy of the License at #
+# #
+# http://www.apache.org/licenses/LICENSE-2.0 #
+# #
+# Unless required by applicable law or agreed to in writing, software #
+# distributed under the License is distributed on an "AS IS" BASIS, #
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. #
+# See the License for the specific language governing permissions and #
+# limitations under the License. #
+################################################################################
{{- if .Values.backupRetention.enabled }}
apiVersion: batch/v1beta1
kind: CronJob
metadata:
- name: {{ include "influxdb.fullname" . }}-backup-retention
+ name: {{ include "common.fullname.influxdb" . }}-backup-retention
labels:
- {{- include "influxdb.labels" . | nindent 4 }}
+ {{- include "common.influxdb.labels" . | nindent 4 }}
app.kubernetes.io/component: backup-retention
annotations:
{{- toYaml .Values.backupRetention.annotations | nindent 4 }}
@@ -21,13 +36,13 @@
{{ toYaml .Values.backupRetention.podAnnotations | nindent 12 }}
{{- end }}
labels:
- {{- include "influxdb.selectorLabels" . | nindent 12 }}
+ {{- include "common.influxdb.selectorLabels" . | nindent 12 }}
spec:
restartPolicy: OnFailure
volumes:
- name: scripts
configMap:
- name: {{ include "influxdb.fullname" . }}-backup-retention
+ name: {{ include "common.fullname.influxdb" . }}-backup-retention
{{- if .Values.backupRetention.gcs }}
{{- if .Values.backupRetention.gcs.serviceAccountSecret }}
- name: google-cloud-key
@@ -42,7 +57,7 @@
secretName: {{ .Values.backupRetention.s3.credentialsSecret | quote }}
{{- end }}
{{- end }}
- serviceAccountName: {{ include "influxdb.serviceAccountName" . }}
+ serviceAccountName: {{ include "common.influxdb.serviceAccountName" . }}
containers:
{{- if .Values.backupRetention.gcs }}
{{- end }}
diff --git a/helm/3rdparty/influxdb/templates/configmap.yaml b/helm/3rdparty/influxdb/templates/configmap.yaml
index ec7677b..c8e289a 100644
--- a/helm/3rdparty/influxdb/templates/configmap.yaml
+++ b/helm/3rdparty/influxdb/templates/configmap.yaml
@@ -1,13 +1,13 @@
apiVersion: v1
kind: ConfigMap
metadata:
- name: {{ include "influxdb.fullname" . }}
+ name: {{ include "common.fullname.influxdb" . }}
labels:
- {{- include "influxdb.labels" . | nindent 4 }}
+ {{- include "common.influxdb.labels" . | nindent 4 }}
data:
influxdb.conf: |+
reporting-disabled = {{ .Values.config.reporting_disabled | default false }}
- bind-address = ":{{ .Values.config.rpc.bind_address | default 8088 }}"
+ bind-address = ":{{ include "common.serviceport.influxdb.rpc.bind_address" . | default 8088 }}"
[meta]
dir = "/var/lib/influxdb/meta"
diff --git a/helm/3rdparty/influxdb/templates/ingress.yaml b/helm/3rdparty/influxdb/templates/ingress.yaml
index bc0a341..49c4fa2 100644
--- a/helm/3rdparty/influxdb/templates/ingress.yaml
+++ b/helm/3rdparty/influxdb/templates/ingress.yaml
@@ -1,10 +1,25 @@
+################################################################################
+# Copyright (c) 2021 HCL Technolgies Limited. #
+# #
+# Licensed under the Apache License, Version 2.0 (the "License"); #
+# you may not use this file except in compliance with the License. #
+# You may obtain a copy of the License at #
+# #
+# http://www.apache.org/licenses/LICENSE-2.0 #
+# #
+# Unless required by applicable law or agreed to in writing, software #
+# distributed under the License is distributed on an "AS IS" BASIS, #
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. #
+# See the License for the specific language governing permissions and #
+# limitations under the License. #
+################################################################################
{{- if .Values.ingress.enabled -}}
apiVersion: networking.k8s.io/v1beta1
kind: Ingress
metadata:
- name: {{ include "influxdb.fullname" . }}
+ name: {{ include "common.fullname.influxdb" . }}
labels:
- {{- include "influxdb.labels" . | nindent 4 }}
+ {{- include "common.influxdb.labels" . | nindent 4 }}
annotations:
{{ toYaml .Values.ingress.annotations | indent 4 }}
spec:
@@ -23,6 +38,6 @@
paths:
- path: {{ .Values.ingress.path }}
backend:
- serviceName: {{ include "influxdb.fullname" . }}
- servicePort: 8086
+ serviceName: {{ include "common.fullname.influxdb" . }}
+ servicePort: {{ include "common.serviceport.influxdb.http" .}}
{{- end -}}
diff --git a/helm/3rdparty/influxdb/templates/init-config.yaml b/helm/3rdparty/influxdb/templates/init-config.yaml
index 5f60898..d57f07c 100644
--- a/helm/3rdparty/influxdb/templates/init-config.yaml
+++ b/helm/3rdparty/influxdb/templates/init-config.yaml
@@ -1,10 +1,25 @@
+################################################################################
+# Copyright (c) 2021 HCL Technolgies Limited. #
+# #
+# Licensed under the Apache License, Version 2.0 (the "License"); #
+# you may not use this file except in compliance with the License. #
+# You may obtain a copy of the License at #
+# #
+# http://www.apache.org/licenses/LICENSE-2.0 #
+# #
+# Unless required by applicable law or agreed to in writing, software #
+# distributed under the License is distributed on an "AS IS" BASIS, #
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. #
+# See the License for the specific language governing permissions and #
+# limitations under the License. #
+################################################################################
{{- if .Values.initScripts.enabled -}}
apiVersion: v1
kind: ConfigMap
metadata:
- name: {{ include "influxdb.fullname" . }}-init
+ name: {{ include "common.fullname.influxdb" . }}-init
labels:
- {{- include "influxdb.labels" . | nindent 4 }}
+ {{- include "common.influxdb.labels" . | nindent 4 }}
data:
{{ toYaml .Values.initScripts.scripts | indent 2 }}
{{- end -}}
diff --git a/helm/3rdparty/influxdb/templates/meta-configmap.yaml b/helm/3rdparty/influxdb/templates/meta-configmap.yaml
index 8e312d1..12d589f 100644
--- a/helm/3rdparty/influxdb/templates/meta-configmap.yaml
+++ b/helm/3rdparty/influxdb/templates/meta-configmap.yaml
@@ -1,15 +1,30 @@
+################################################################################
+# Copyright (c) 2021 HCL Technolgies Limited. #
+# #
+# Licensed under the Apache License, Version 2.0 (the "License"); #
+# you may not use this file except in compliance with the License. #
+# You may obtain a copy of the License at #
+# #
+# http://www.apache.org/licenses/LICENSE-2.0 #
+# #
+# Unless required by applicable law or agreed to in writing, software #
+# distributed under the License is distributed on an "AS IS" BASIS, #
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. #
+# See the License for the specific language governing permissions and #
+# limitations under the License. #
+################################################################################
{{ if .Values.enterprise.enabled -}}
apiVersion: v1
kind: ConfigMap
metadata:
- name: {{ include "influxdb.fullname" . }}-meta
+ name: {{ include "common.fullname.influxdb" . }}-meta
labels:
- {{- include "influxdb.labels" . | nindent 4 }}
+ {{- include "common.influxdb.labels" . | nindent 4 }}
app.kubernetes.io/component: meta
data:
influxdb-meta.conf: |+
reporting-disabled = {{ .Values.config.reporting_disabled | default false }}
- bind-address = ":{{ .Values.config.meta.bind_address | default 8091 }}"
+ bind-address = ":{{ include "common.serviceport.influxdb.meta.bind_address" . | default 8091 }}"
[enterprise]
license-key = {{ .Values.enterprise.licensekey | quote }}
diff --git a/helm/3rdparty/influxdb/templates/meta-service.yaml b/helm/3rdparty/influxdb/templates/meta-service.yaml
index 78d18e5..0ee4aae 100644
--- a/helm/3rdparty/influxdb/templates/meta-service.yaml
+++ b/helm/3rdparty/influxdb/templates/meta-service.yaml
@@ -1,3 +1,18 @@
+################################################################################
+# Copyright (c) 2021 HCL Technolgies Limited. #
+# #
+# Licensed under the Apache License, Version 2.0 (the "License"); #
+# you may not use this file except in compliance with the License. #
+# You may obtain a copy of the License at #
+# #
+# http://www.apache.org/licenses/LICENSE-2.0 #
+# #
+# Unless required by applicable law or agreed to in writing, software #
+# distributed under the License is distributed on an "AS IS" BASIS, #
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. #
+# See the License for the specific language governing permissions and #
+# limitations under the License. #
+################################################################################
{{ if .Values.enterprise.enabled -}}
apiVersion: v1
kind: Service
@@ -6,9 +21,9 @@
annotations:
{{ toYaml .Values.service.annotations | indent 4 }}
{{- end }}
- name: {{ include "influxdb.fullname" . }}-meta
+ name: {{ include "common.fullname.influxdb" . }}-meta
labels:
- {{- include "influxdb.labels" . | nindent 4 }}
+ {{- include "common.influxdb.labels" . | nindent 4 }}
app.kubernets.io/component: meta
spec:
type: ClusterIP
@@ -17,9 +32,9 @@
publishNotReadyAddresses: true
ports:
- name: meta
- port: {{ .Values.config.meta.bind_address | default 8091 }}
+ port: {{ include "common.serviceport.influxdb.meta.bind_address" . | default 8091 }}
targetPort: meta
selector:
- {{- include "influxdb.selectorLabels" . | nindent 4 }}
+ {{- include "common.influxdb.selectorLabels" . | nindent 4 }}
app.kubernets.io/component: meta
{{- end }}
diff --git a/helm/3rdparty/influxdb/templates/meta-statefulset.yaml b/helm/3rdparty/influxdb/templates/meta-statefulset.yaml
index 16b35c4..baf7f2c 100644
--- a/helm/3rdparty/influxdb/templates/meta-statefulset.yaml
+++ b/helm/3rdparty/influxdb/templates/meta-statefulset.yaml
@@ -1,22 +1,37 @@
+################################################################################
+# Copyright (c) 2021 HCL Technolgies Limited. #
+# #
+# Licensed under the Apache License, Version 2.0 (the "License"); #
+# you may not use this file except in compliance with the License. #
+# You may obtain a copy of the License at #
+# #
+# http://www.apache.org/licenses/LICENSE-2.0 #
+# #
+# Unless required by applicable law or agreed to in writing, software #
+# distributed under the License is distributed on an "AS IS" BASIS, #
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. #
+# See the License for the specific language governing permissions and #
+# limitations under the License. #
+################################################################################
{{- if .Values.enterprise.enabled }}
apiVersion: apps/v1
kind: StatefulSet
metadata:
- name: {{ include "influxdb.fullname" . }}-meta
+ name: {{ include "common.fullname.influxdb" . }}-meta
labels:
- {{- include "influxdb.labels" . | nindent 4 }}
+ {{- include "common.influxdb.labels" . | nindent 4 }}
app.kubernetes.io/component: meta
spec:
replicas: {{ .Values.enterprise.meta.clusterSize }}
selector:
matchLabels:
- {{- include "influxdb.selectorLabels" . | nindent 6 }}
+ {{- include "common.influxdb.selectorLabels" . | nindent 6 }}
app.kubernetes.io/component: meta
- serviceName: "{{ include "influxdb.fullname" . }}-meta"
+ serviceName: "{{ include "common.fullname.influxdb" . }}-meta"
template:
metadata:
labels:
- {{- include "influxdb.selectorLabels" . | nindent 8 }}
+ {{- include "common.influxdb.selectorLabels" . | nindent 8 }}
app.kubernetes.io/component: meta
{{- if .Values.podAnnotations }}
annotations:
@@ -29,26 +44,26 @@
- name: {{ . }}
{{- end}}
{{- end }}
- serviceAccountName: {{ include "influxdb.serviceAccountName" . }}
+ serviceAccountName: {{ include "common.influxdb.serviceAccountName" . }}
containers:
- - name: "{{ include "influxdb.fullname" . }}-meta"
+ - name: "{{ include "common.fullname.influxdb" . }}-meta"
image: "{{ .Values.image.repository }}:{{ .Values.enterprise.meta.image.tag }}"
imagePullPolicy: {{ .Values.image.pullPolicy | quote }}
resources:
{{ toYaml .Values.enterprise.meta.resources | indent 10 }}
ports:
- name: udp
- containerPort: {{ .Values.config.udp.bind_address | default 8089 }}
+ containerPort: {{ include "common.serviceport.influxdb.udp.bind_address" . | default 8089 }}
- name: rpc
- containerPort: {{ .Values.config.rpc.bind_address | default 8088 }}
+ containerPort: {{ include "common.serviceport.influxdb.rpc.bind_address" . | default 8088 }}
- name: meta
- containerPort: {{ .Values.config.meta.bind_address | default 8091 }}
+ containerPort: {{ include "common.serviceport.influxdb.meta.bind_address" . | default 8091 }}
{{- if .Values.env }}
env:
{{ toYaml .Values.env | indent 10 }}
# Values.env's HOSTNAME isn't fundamentally different from $HOSTNAME, but this way we get a distinguished name for InfluxDB at runtime.
- name: INFLUXDB_HOSTNAME
- value: "$(_HOSTNAME).{{ include "influxdb.fullname" . }}-meta"
+ value: "$(_HOSTNAME).{{ include "common.fullname.influxdb" . }}-meta"
{{- end }}
livenessProbe:
httpGet:
@@ -71,7 +86,7 @@
periodSeconds: {{ .Values.startupProbe.periodSeconds | default 5 }}
{{- end }}
volumeMounts:
- - name: {{ include "influxdb.fullname" . }}-meta
+ - name: {{ include "common.fullname.influxdb" . }}-meta
mountPath: /var/lib/influxdb
- name: config
mountPath: /etc/influxdb
@@ -82,14 +97,14 @@
volumes:
- name: config
configMap:
- name: {{ include "influxdb.fullname" . }}-meta
+ name: {{ include "common.fullname.influxdb" . }}-meta
{{- if .Values.initScripts.enabled }}
- name: init
configMap:
- name: {{ include "influxdb.fullname" . }}-init
+ name: {{ include "common.fullname.influxdb" . }}-init
{{- end }}
{{- if (not .Values.persistence.enabled ) }}
- - name: {{ include "influxdb.fullname" . }}-meta
+ - name: {{ include "common.fullname.influxdb" . }}-meta
emptyDir: {}
{{- end }}
{{- if .Values.schedulerName }}
@@ -110,7 +125,7 @@
{{- if .Values.persistence.enabled }}
volumeClaimTemplates:
- metadata:
- name: {{ include "influxdb.fullname" . }}-meta
+ name: {{ include "common.fullname.influxdb" . }}-meta
annotations:
{{- range $key, $value := .Values.persistence.annotations }}
{{ $key }}: "{{ $value }}"
diff --git a/helm/3rdparty/influxdb/templates/post-install-set-auth.yaml b/helm/3rdparty/influxdb/templates/post-install-set-auth.yaml
index aa77667..7963412 100644
--- a/helm/3rdparty/influxdb/templates/post-install-set-auth.yaml
+++ b/helm/3rdparty/influxdb/templates/post-install-set-auth.yaml
@@ -1,10 +1,25 @@
+################################################################################
+# Copyright (c) 2021 HCL Technolgies Limited. #
+# #
+# Licensed under the Apache License, Version 2.0 (the "License"); #
+# you may not use this file except in compliance with the License. #
+# You may obtain a copy of the License at #
+# #
+# http://www.apache.org/licenses/LICENSE-2.0 #
+# #
+# Unless required by applicable law or agreed to in writing, software #
+# distributed under the License is distributed on an "AS IS" BASIS, #
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. #
+# See the License for the specific language governing permissions and #
+# limitations under the License. #
+################################################################################
{{- if .Values.setDefaultUser.enabled -}}
apiVersion: batch/v1
kind: Job
metadata:
- name: {{ include "influxdb.fullname" . }}-set-auth
+ name: {{ include "common.fullname.influxdb" . }}-set-auth
labels:
- {{- include "influxdb.labels" . | nindent 4 }}
+ {{- include "common.influxdb.labels" . | nindent 4 }}
annotations:
"helm.sh/hook": post-install
"helm.sh/hook-delete-policy": {{ .Values.setDefaultUser.hookDeletePolicy }}
@@ -14,10 +29,10 @@
template:
metadata:
labels:
- {{- include "influxdb.selectorLabels" . | nindent 8 }}
+ {{- include "common.influxdb.selectorLabels" . | nindent 8 }}
spec:
containers:
- - name: {{ include "influxdb.fullname" . }}-set-auth
+ - name: {{ include "common.fullname.influxdb" . }}-set-auth
image: "{{ .Values.setDefaultUser.image }}"
env:
- name: INFLUXDB_USER
@@ -26,7 +41,7 @@
{{- if .Values.setDefaultUser.user.existingSecret }}
name: {{ .Values.setDefaultUser.user.existingSecret -}}
{{ else }}
- name: {{ include "influxdb.fullname" . }}-auth
+ name: {{ include "common.fullname.influxdb" . }}-auth
{{- end }}
key: influxdb-user
- name: INFLUXDB_PASSWORD
@@ -35,14 +50,14 @@
{{- if .Values.setDefaultUser.user.existingSecret }}
name: {{ .Values.setDefaultUser.user.existingSecret -}}
{{ else }}
- name: {{ include "influxdb.fullname" . }}-auth
+ name: {{ include "common.fullname.influxdb" . }}-auth
{{- end }}
key: influxdb-password
args:
- "/bin/sh"
- "-c"
- |
- curl -X POST http://{{ include "influxdb.fullname" . }}:{{ .Values.config.http.bind_address | default 8086 }}/query \
+ curl -X POST http://{{ include "common.fullname.influxdb" . }}:{{ include "common.serviceport.influxdb.http.bind_address" . | default 8086 }}/query \
--data-urlencode \
"q=CREATE USER \"${INFLUXDB_USER}\" WITH PASSWORD '${INFLUXDB_PASSWORD}' {{ .Values.setDefaultUser.user.privileges }}"
restartPolicy: {{ .Values.setDefaultUser.restartPolicy }}
diff --git a/helm/3rdparty/influxdb/templates/secret.yaml b/helm/3rdparty/influxdb/templates/secret.yaml
index c6390f1..c777849 100644
--- a/helm/3rdparty/influxdb/templates/secret.yaml
+++ b/helm/3rdparty/influxdb/templates/secret.yaml
@@ -1,11 +1,26 @@
+################################################################################
+# Copyright (c) 2021 HCL Technolgies Limited. #
+# #
+# Licensed under the Apache License, Version 2.0 (the "License"); #
+# you may not use this file except in compliance with the License. #
+# You may obtain a copy of the License at #
+# #
+# http://www.apache.org/licenses/LICENSE-2.0 #
+# #
+# Unless required by applicable law or agreed to in writing, software #
+# distributed under the License is distributed on an "AS IS" BASIS, #
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. #
+# See the License for the specific language governing permissions and #
+# limitations under the License. #
+################################################################################
{{- if .Values.setDefaultUser.enabled -}}
{{- if not (.Values.setDefaultUser.user.existingSecret) -}}
apiVersion: v1
kind: Secret
metadata:
- name: {{ include "influxdb.fullname" . }}-auth
+ name: {{ include "common.fullname.influxdb" . }}-auth
labels:
- {{- include "influxdb.labels" . | nindent 4 }}
+ {{- include "common.influxdb.labels" . | nindent 4 }}
data:
{{- if .Values.setDefaultUser.user.password }}
influxdb-password: {{ .Values.setDefaultUser.user.password | b64enc | quote }}
diff --git a/helm/3rdparty/influxdb/templates/service.yaml b/helm/3rdparty/influxdb/templates/service.yaml
index c5121e5..d226f2d 100644
--- a/helm/3rdparty/influxdb/templates/service.yaml
+++ b/helm/3rdparty/influxdb/templates/service.yaml
@@ -1,3 +1,18 @@
+################################################################################
+# Copyright (c) 2021 HCL Technolgies Limited. #
+# #
+# Licensed under the Apache License, Version 2.0 (the "License"); #
+# you may not use this file except in compliance with the License. #
+# You may obtain a copy of the License at #
+# #
+# http://www.apache.org/licenses/LICENSE-2.0 #
+# #
+# Unless required by applicable law or agreed to in writing, software #
+# distributed under the License is distributed on an "AS IS" BASIS, #
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. #
+# See the License for the specific language governing permissions and #
+# limitations under the License. #
+################################################################################
apiVersion: v1
kind: Service
metadata:
@@ -5,42 +20,42 @@
annotations:
{{ toYaml .Values.service.annotations | indent 4 }}
{{- end }}
- name: {{ include "influxdb.fullname" . }}
+ name: {{ include "common.fullname.influxdb" . }}
labels:
- {{- include "influxdb.labels" . | nindent 4 }}
+ {{- include "common.influxdb.labels" . | nindent 4 }}
spec:
type: {{ .Values.service.type }}
ports:
- name: api
- port: {{ .Values.config.http.bind_address | default 8086 }}
+ port: {{ include "common.serviceport.influxdb.http.bind_address" . | default 8086 }}
targetPort: api
- name: rpc
- port: {{ .Values.config.rpc.bind_address | default 8088 }}
+ port: {{ include "common.serviceport.influxdb.rpc.bind_address" . | default 8088 }}
targetPort: rpc
{{- if .Values.config.graphite.enabled }}
- name: graphite
- port: {{ .Values.config.graphite.bind_address | default 2003 }}
+ port: {{ include "common.serviceport.influxdb.graphite.bind_address" . | default 2003 }}
targetPort: graphite
{{- end }}
{{- if .Values.config.collectd.enabled }}
- name: collectd
- port: {{ .Values.config.collectd.bind_address | default 25826 }}
+ port: {{ include "common.serviceport.influxdb.collectd.bind_address" . | default 25826 }}
protocol: UDP
targetPort: collectd
{{- end }}
{{- if .Values.config.udp.enabled }}
- name: udp
- port: {{ .Values.config.udp.bind_address | default 8089 }}
+ port: {{ include "common.serviceport.influxdb.udp.bind_address" . | default 8089 }}
protocol: UDP
targetPort: udp
{{- end }}
{{- if .Values.config.opentsdb.enabled }}
- name: opentsdb
- port: {{ .Values.config.opentsdb.bind_address | default 4242 }}
+ port: {{ include "common.serviceport.influxdb.opentsdb.bind_address" . | default 4242 }}
targetPort: opentsdb
{{- end }}
selector:
- {{- include "influxdb.selectorLabels" . | nindent 4 }}
+ {{- include "common.influxdb.selectorLabels" . | nindent 4 }}
{{- if .Values.service.loadBalancerIP }}
loadBalancerIP: {{ .Values.service.loadBalancerIP }}
{{- end }}
diff --git a/helm/3rdparty/influxdb/templates/serviceaccount.yaml b/helm/3rdparty/influxdb/templates/serviceaccount.yaml
index c496696..3c586fb 100644
--- a/helm/3rdparty/influxdb/templates/serviceaccount.yaml
+++ b/helm/3rdparty/influxdb/templates/serviceaccount.yaml
@@ -1,12 +1,28 @@
+################################################################################
+# Copyright (c) 2021 HCL Technolgies Limited. #
+# #
+# Licensed under the Apache License, Version 2.0 (the "License"); #
+# you may not use this file except in compliance with the License. #
+# You may obtain a copy of the License at #
+# #
+# http://www.apache.org/licenses/LICENSE-2.0 #
+# #
+# Unless required by applicable law or agreed to in writing, software #
+# distributed under the License is distributed on an "AS IS" BASIS, #
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. #
+# See the License for the specific language governing permissions and #
+# limitations under the License. #
+################################################################################
+---
{{- if .Values.serviceAccount.create -}}
apiVersion: v1
kind: ServiceAccount
metadata:
- name: {{ include "influxdb.serviceAccountName" . }}
+ name: {{ include "common.influxdb.serviceAccountName" . }}
labels:
- {{- include "influxdb.labels" . | nindent 4 }}
+ {{- include "common.influxdb.labels" . | nindent 4 }}
{{- with .Values.serviceAccount.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
- {{- end }}
+ {{- end }}
{{- end -}}
diff --git a/helm/3rdparty/influxdb/templates/statefulset.yaml b/helm/3rdparty/influxdb/templates/statefulset.yaml
index 13eda03..eac8870 100644
--- a/helm/3rdparty/influxdb/templates/statefulset.yaml
+++ b/helm/3rdparty/influxdb/templates/statefulset.yaml
@@ -1,9 +1,24 @@
+################################################################################
+# Copyright (c) 2021 HCL Technolgies Limited. #
+# #
+# Licensed under the Apache License, Version 2.0 (the "License"); #
+# you may not use this file except in compliance with the License. #
+# You may obtain a copy of the License at #
+# #
+# http://www.apache.org/licenses/LICENSE-2.0 #
+# #
+# Unless required by applicable law or agreed to in writing, software #
+# distributed under the License is distributed on an "AS IS" BASIS, #
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. #
+# See the License for the specific language governing permissions and #
+# limitations under the License. #
+################################################################################
apiVersion: apps/v1
kind: StatefulSet
metadata:
- name: {{ include "influxdb.fullname" . }}
+ name: {{ include "common.fullname.influxdb" . }}-meta
labels:
- {{- include "influxdb.labels" . | nindent 4 }}
+ {{- include "common.influxdb.labels" . | nindent 4 }}
spec:
{{- if .Values.enterprise.enabled }}
replicas: {{ .Values.enterprise.clusterSize }}
@@ -12,12 +27,12 @@
{{- end}}
selector:
matchLabels:
- {{- include "influxdb.selectorLabels" . | nindent 6 }}
- serviceName: "{{ include "influxdb.fullname" . }}"
+ {{- include "common.influxdb.selectorLabels" . | nindent 6 }}
+ serviceName: {{ include "common.fullname.influxdb" . }}-meta
template:
metadata:
labels:
- {{- include "influxdb.selectorLabels" . | nindent 8 }}
+ {{- include "common.influxdb.selectorLabels" . | nindent 8 }}
{{- if .Values.podAnnotations }}
annotations:
{{ toYaml .Values.podAnnotations | indent 8 }}
@@ -48,46 +63,46 @@
- name: {{ . }}
{{- end}}
{{- end }}
- serviceAccountName: {{ include "influxdb.serviceAccountName" . }}
+ serviceAccountName: {{ include "common.influxdb.serviceAccountName" . }}
containers:
- - name: {{ include "influxdb.fullname" . }}
+ - name: {{ include "common.fullname.influxdb" . }}
image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
imagePullPolicy: {{ .Values.image.pullPolicy | quote }}
resources:
{{ toYaml .Values.resources | indent 10 }}
ports:
- name: api
- containerPort: {{ .Values.config.http.bind_address | default 8086 }}
+ containerPort: {{ include "common.serviceport.influxdb.http.bind_address" . | default 8086 }}
{{- if .Values.config.graphite.enabled }}
- name: graphite
- containerPort: {{ .Values.config.graphite.bind_address | default 2003 }}
+ containerPort: {{ include "common.serviceport.influxdb.graphite.bind_address" . | default 2003 }}
{{- end }}
{{- if .Values.config.collectd.enabled }}
- name: collectd
- containerPort: {{ .Values.config.collectd.bind_address | default 25826 }}
+ containerPort: {{ include "common.serviceport.influxdb.collectd.bind_address" . | default 25826 }}
protocol: UDP
{{- end }}
{{- if .Values.config.udp.enabled }}
- name: udp
- containerPort: {{ .Values.config.udp.bind_address | default 8089 }}
+ containerPort: {{ include "common.serviceport.influxdb.udp.bind_address" . | default 8089 }}
protocol: UDP
{{- end }}
{{- if .Values.config.opentsdb.enabled }}
- name: opentsdb
- containerPort: {{ .Values.config.opentsdb.bind_address | default 4242 }}
+ containerPort: {{ include "common.serviceport.influxdb.opentsdb.bind_address" . | default 4242 }}
{{- end }}
- name: rpc
- containerPort: {{ .Values.config.rpc.bind_address | default 8088 }}
+ containerPort: {{ include "common.serviceport.influxdb.rpc.bind_address" . | default 8088 }}
{{- if .Values.enterprise.enabled }}
- name: meta
- containerPort: {{ .Values.config.meta.bind_address | default 8091 }}
+ containerPort: {{ include "common.serviceport.influxdb.meta.bind_address" . | default 8091 }}
{{- end }}
{{- if .Values.env }}
env:
{{ toYaml .Values.env | indent 10 }}
{{- if .Values.enterprise.enabled }}
- name: INFLUXDB_HOSTNAME # Values.env's HOSTNAME isn't fundamentally different from $HOSTNAME, but this way weg get a distinguished name at runtime.
- value: "$(_HOSTNAME).{{ include "influxdb.fullname" . }}"
+ value: "$(_HOSTNAME).{{ include "common.fullname.influxdb" . }}"
{{- end }}
{{- end }}
{{- if .Values.envFromSecret }}
@@ -119,7 +134,7 @@
periodSeconds: {{ .Values.startupProbe.periodSeconds | default 5 }}
{{- end }}
volumeMounts:
- - name: {{ include "influxdb.fullname" . }}-data
+ - name: {{ include "common.fullname.influxdb" . }}-data
mountPath: /var/lib/influxdb
- name: config
mountPath: /etc/influxdb
@@ -136,19 +151,19 @@
volumes:
- name: config
configMap:
- name: {{ include "influxdb.fullname" . }}
+ name: {{ include "common.fullname.influxdb" . }}
{{- if .Values.initScripts.enabled }}
- name: init
configMap:
- name: {{ include "influxdb.fullname" . }}-init
+ name: {{ include "common.fullname.influxdb" . }}-init
{{- end }}
{{- if (not .Values.persistence.enabled ) }}
- - name: {{ include "influxdb.fullname" . }}-data
+ - name: {{ include "common.fullname.influxdb" . }}-data
emptyDir: {}
{{- end }}
# Cannot use existing claim in enterprise mode
{{- if and .Values.persistence.enabled .Values.persistence.existingClaim (not .Values.enterprise.enabled) }}
- - name: {{ include "influxdb.fullname" . }}-data
+ - name: {{ include "common.fullname.influxdb" . }}-data
persistentVolumeClaim:
claimName: {{ .Values.persistence.existingClaim }}
{{- end }}
@@ -159,7 +174,7 @@
{{- if and .Values.persistence.enabled (or (not .Values.persistence.existingClaim) .Values.enterprise.enabled) }}
volumeClaimTemplates:
- metadata:
- name: {{ include "influxdb.fullname" . }}-data
+ name: {{ include "common.fullname.influxdb" . }}-data
annotations:
{{- range $key, $value := .Values.persistence.annotations }}
{{ $key }}: "{{ $value }}"