apiVersion: apps/v1 kind: StatefulSet metadata: name: {{ template "hbase.name" . }}-rs labels: app: {{ template "hbase.name" . }} chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }} release: {{ .Release.Name }} heritage: {{ .Release.Service }} component: hbase-rs spec: serviceName: {{ template "hbase.name" . }}-rs replicas: {{ .Values.hdfs.dataNode.replicas }} selector: matchLabels: app: {{ template "hbase.name" . }} release: {{ .Release.Name }} component: hbase-rs template: metadata: labels: app: {{ template "hbase.name" . }} release: {{ .Release.Name }} component: hbase-rs spec: affinity: podAntiAffinity: requiredDuringSchedulingIgnoredDuringExecution: - topologyKey: "kubernetes.io/hostname" labelSelector: matchLabels: app: {{ .Values.hbase.hdfs.name }} release: {{ .Values.hbase.hdfs.release | quote }} component: hdfs-nn terminationGracePeriodSeconds: 0 containers: - name: hbase-rs image: {{ .Values.hbaseImage }} imagePullPolicy: {{ .Values.imagePullPolicy }} command: - "/bin/bash" - "/tmp/hbase-config/bootstrap.sh" resources: {{ toYaml .Values.hdfs.nameNode.resources | indent 10 }} readinessProbe: httpGet: path: / port: 16030 initialDelaySeconds: 5 timeoutSeconds: 2 livenessProbe: httpGet: path: / port: 16030 initialDelaySeconds: 10 timeoutSeconds: 2 volumeMounts: - name: hbase-config mountPath: /tmp/hbase-config volumes: - name: hbase-config configMap: name: hbase-configmap