From 9ae0fc986329c2abbd7b2c2c513f1625afd53c63 Mon Sep 17 00:00:00 2001 From: diandian Date: Mon, 27 Nov 2023 23:48:08 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=20'hbase-master'?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- hbase-master | 197 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 197 insertions(+) create mode 100644 hbase-master diff --git a/hbase-master b/hbase-master new file mode 100644 index 0000000..db3d34d --- /dev/null +++ b/hbase-master @@ -0,0 +1,197 @@ +--- +apiVersion: apps/v1 +kind: StatefulSet +metadata: + annotations: + checksum/config: ce5ee657e4d8a2a9e72c3741bce44c87d12947f5e29019c8bbc78b5d5754b106 + meta.helm.sh/release-name: hbase + meta.helm.sh/release-namespace: hbase + labels: + app.kubernetes.io/component: master + app.kubernetes.io/instance: hbase + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/name: hbase + app.kubernetes.io/part-of: hbase + app.kubernetes.io/version: 2.4.13 + helm.sh/chart: hbase-0.1.7 + name: hbase-hbase-master + namespace: hbase + resourceVersion: '36964347' +spec: + persistentVolumeClaimRetentionPolicy: + whenDeleted: Retain + whenScaled: Retain + podManagementPolicy: OrderedReady + replicas: 2 + revisionHistoryLimit: 10 + selector: + matchLabels: + app.kubernetes.io/component: master + app.kubernetes.io/instance: hbase + app.kubernetes.io/name: hbase + serviceName: hbase-hbase-master + template: + metadata: + creationTimestamp: null + labels: + app.kubernetes.io/component: master + app.kubernetes.io/instance: hbase + app.kubernetes.io/name: hbase + spec: + affinity: + podAntiAffinity: + preferredDuringSchedulingIgnoredDuringExecution: + - podAffinityTerm: + labelSelector: + matchLabels: + app.kubernetes.io/component: master + app.kubernetes.io/instance: hbase + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/name: hbase + app.kubernetes.io/part-of: hbase + app.kubernetes.io/version: 2.4.13 + helm.sh/chart: hbase-0.1.7 + topologyKey: kubernetes.io/hostname + weight: 5 + containers: + - command: + - /bin/bash + - /tmp/hbase-config/bootstrap.sh + - '-d' + - master + env: + - name: HADOOP_USER_NAME + value: root + image: 'ghcr.io/fleeksoft/hbase/hbase-base:2.4.13.2' + imagePullPolicy: IfNotPresent + livenessProbe: + failureThreshold: 3 + httpGet: + path: / + port: 16010 + scheme: HTTP + initialDelaySeconds: 10 + periodSeconds: 10 + successThreshold: 1 + timeoutSeconds: 2 + name: master + readinessProbe: + failureThreshold: 3 + httpGet: + path: / + port: 16010 + scheme: HTTP + initialDelaySeconds: 90 + periodSeconds: 10 + successThreshold: 1 + timeoutSeconds: 2 + resources: + limits: + cpu: '1' + memory: 2Gi + requests: + cpu: 10m + memory: 256Mi + startupProbe: + failureThreshold: 60 + httpGet: + path: / + port: 16010 + scheme: HTTP + periodSeconds: 5 + successThreshold: 1 + timeoutSeconds: 2 + terminationMessagePath: /dev/termination-log + terminationMessagePolicy: File + volumeMounts: + - mountPath: /tmp/hbase-config + name: hbase-config + - mountPath: /jmx-exporter + name: jmx-exporter + - mountPath: /etc/exporter + name: exporter-config + dnsPolicy: ClusterFirst + initContainers: + - env: + - name: SHARED_VOLUME_PATH + value: /jmx-exporter + image: 'spdigital/prometheus-jmx-exporter-kubernetes:0.3.1' + imagePullPolicy: IfNotPresent + name: inject-exporter-jar + resources: {} + terminationMessagePath: /dev/termination-log + terminationMessagePolicy: File + volumeMounts: + - mountPath: /jmx-exporter + name: jmx-exporter + restartPolicy: Always + schedulerName: default-scheduler + securityContext: {} + terminationGracePeriodSeconds: 30 + volumes: + - configMap: + defaultMode: 420 + name: hbase-hbase + name: hbase-config + - emptyDir: {} + name: jmx-exporter + - configMap: + defaultMode: 420 + name: hbase-hbase-exporter + name: exporter-config + updateStrategy: + rollingUpdate: + partition: 0 + type: RollingUpdate + +--- +apiVersion: v1 +kind: Service +metadata: + annotations: + meta.helm.sh/release-name: hbase + meta.helm.sh/release-namespace: hbase + labels: + app.kubernetes.io/component: master + app.kubernetes.io/instance: hbase + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/name: hbase + app.kubernetes.io/part-of: hbase + app.kubernetes.io/version: 2.4.13 + helm.sh/chart: hbase-0.1.7 + name: hbase-hbase-master + namespace: hbase + resourceVersion: '36780930' +spec: + clusterIP: None + clusterIPs: + - None + internalTrafficPolicy: Cluster + ipFamilies: + - IPv4 + ipFamilyPolicy: SingleStack + ports: + - name: thrift + port: 9090 + protocol: TCP + targetPort: 9090 + - name: thrift-ui + port: 9095 + protocol: TCP + targetPort: 9095 + - name: hbase-master + port: 16000 + protocol: TCP + targetPort: 16000 + - name: hbase-ui + port: 16010 + protocol: TCP + targetPort: 16010 + publishNotReadyAddresses: true + selector: + app.kubernetes.io/component: master + app.kubernetes.io/instance: hbase + app.kubernetes.io/name: hbase + sessionAffinity: None + type: ClusterIP +