aboutsummaryrefslogtreecommitdiffstats
path: root/kubernetes/dmaap/components/dmaap-dr-node/templates/statefulset.yaml
diff options
context:
space:
mode:
Diffstat (limited to 'kubernetes/dmaap/components/dmaap-dr-node/templates/statefulset.yaml')
-rw-r--r--kubernetes/dmaap/components/dmaap-dr-node/templates/statefulset.yaml71
1 files changed, 24 insertions, 47 deletions
diff --git a/kubernetes/dmaap/components/dmaap-dr-node/templates/statefulset.yaml b/kubernetes/dmaap/components/dmaap-dr-node/templates/statefulset.yaml
index 69f6fc1d6e..f4167afe2f 100644
--- a/kubernetes/dmaap/components/dmaap-dr-node/templates/statefulset.yaml
+++ b/kubernetes/dmaap/components/dmaap-dr-node/templates/statefulset.yaml
@@ -24,35 +24,18 @@ spec:
metadata: {{- include "common.templateMetadata" . | nindent 6 }}
spec:
{{ include "common.podSecurityContext" . | indent 6 | trim}}
- initContainers: {{ include "common.certInitializer.initContainer" . | nindent 8 }}
- - name: {{ include "common.name" . }}-readiness
- securityContext:
- runAsUser: 100
- runAsGroup: 65533
- image: {{ include "repositoryGenerator.image.readiness" . }}
- imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
- command:
- - /app/ready.py
- args:
- - --container-name
- - dmaap-dr-prov
- env:
- - name: NAMESPACE
- valueFrom:
- fieldRef:
- apiVersion: v1
- fieldPath: metadata.namespace
+ initContainers: {{ include "common.readinessCheck.waitFor" . | nindent 8 }}
- name: {{ include "common.name" . }}-permission-fixer
securityContext:
runAsUser: 0
image: {{ include "repositoryGenerator.image.busybox" . }}
imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
- volumeMounts: {{ include "common.certInitializer.volumeMount" . | nindent 10 }}
- - mountPath: {{ .Values.persistence.spool.path }}
- name: {{ include "common.fullname" . }}-spool
- - mountPath: {{ .Values.persistence.event.path }}
- name: {{ include "common.fullname" . }}-event-logs
command: ["chown","-Rf","1000:1001", "/opt/app/"]
+ volumeMounts:
+ - name: {{ include "common.fullname" . }}-spool
+ mountPath: {{ .Values.persistence.spool.path }}
+ - name: {{ include "common.fullname" . }}-event-logs
+ mountPath: {{ .Values.persistence.event.path }}
containers:
- name: {{ include "common.name" . }}
image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }}
@@ -70,50 +53,44 @@ spec:
port: {{.Values.readiness.port}}
initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }}
periodSeconds: {{ .Values.readiness.periodSeconds }}
- volumeMounts: {{ include "common.certInitializer.volumeMount" . | nindent 10 }}
- - mountPath: {{ .Values.persistence.spool.path }}
- name: {{ include "common.fullname" . }}-spool
- - mountPath: {{ .Values.persistence.event.path }}
- name: {{ include "common.fullname" . }}-event-logs
- - mountPath: /etc/localtime
- name: localtime
- readOnly: false
- - mountPath: /opt/app/datartr/etc/node.properties
- name: {{ include "common.fullname" . }}-config
- subPath: node.properties
- - mountPath: /opt/app/datartr/etc/logback.xml
- name: {{ include "common.fullname" . }}-log-conf
- subPath: logback.xml
- - mountPath: {{ .Values.global.loggingDirectory }}
- name: logs
- resources: {{ include "common.resources" . | nindent 12 }}
+ volumeMounts:
+ - mountPath: {{ .Values.persistence.spool.path }}
+ name: {{ include "common.fullname" . }}-spool
+ - mountPath: {{ .Values.persistence.event.path }}
+ name: {{ include "common.fullname" . }}-event-logs
+ - mountPath: /etc/localtime
+ name: localtime
+ readOnly: false
+ - mountPath: /opt/app/datartr/etc/node.properties
+ name: {{ include "common.fullname" . }}-config
+ subPath: node.properties
+ - mountPath: /opt/app/datartr/etc/logback.xml
+ name: {{ include "common.fullname" . }}-log-conf
+ subPath: logback.xml
+ resources:
+{{ include "common.resources" . }}
{{- if .Values.nodeSelector }}
nodeSelector: {{ toYaml .Values.nodeSelector | nindent 10 }}
{{- end -}}
{{- if .Values.affinity }}
affinity: {{ toYaml .Values.affinity | nindent 10 }}
{{- end }}
- # Filebeat sidecar container
- {{ include "common.log.sidecar" . | nindent 8 }}
imagePullSecrets:
- name: "{{ include "common.namespace" . }}-docker-registry-key"
serviceAccountName: {{ include "common.fullname" (dict "suffix" "read" "dot" . )}}
- volumes: {{ include "common.certInitializer.volumes" . | nindent 8 }}
+ volumes:
- name: localtime
hostPath:
path: /etc/localtime
- name: {{ include "common.fullname" . }}-config
configMap:
- name: {{ include "common.fullname" . }}-configmap
+ name: {{ include "common.fullname" . }}-node-props
items:
- key: node.properties
path: node.properties
- name: {{ include "common.fullname" . }}-log-conf
configMap:
name: {{ include "common.fullname" . }}-log
- {{ include "common.log.volumes" . | nindent 8 }}
- - name: logs
- emptyDir: {}
{{- if not .Values.persistence.enabled }}
- name: {{ include "common.fullname" . }}-event-logs
emptyDir: {}