This is an automated email from the ASF dual-hosted git repository.
zhongxjian pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/dubbo-kubernetes.git
The following commit(s) were added to refs/heads/master by this push:
new acc1bd89 [charts] Add values and add a pre ingress controller
annotation to csi storage (#678)
acc1bd89 is described below
commit acc1bd89d823efceb0d6d4fd86eccc4679a3b5ea
Author: Jian Zhong <[email protected]>
AuthorDate: Mon Apr 14 07:58:12 2025 +0800
[charts] Add values and add a pre ingress controller annotation to csi
storage (#678)
---
manifests/addons/gen.sh | 56 ++---------
manifests/addons/values-grafana.yaml | 39 --------
manifests/addons/values-prometheus.yaml | 16 +++
manifests/addons/values-skywalking.yaml | 27 -----
manifests/addons/values-zipkin.yaml | 27 -----
manifests/addons/values-zookeeper.yaml | 25 -----
manifests/charts/admin/templates/deployment.yaml | 30 +++---
manifests/charts/admin/values.yaml | 7 +-
.../charts/base/templates/ingress-controller.yaml | 63 ++++++++++++
.../base/templates/{jobs.yaml => rook-jobs.yaml} | 110 +++++++++++----------
manifests/charts/base/values.yaml | 49 +++++++++
.../nacos/templates/mysql-configmap.yaml | 3 +-
.../nacos/templates/mysql-service.yaml | 7 +-
.../nacos/templates/mysql-statefulset.yaml | 44 ++++-----
.../nacos/templates/statefulset.yaml | 46 ++++-----
.../register-discovery/nacos/values.yaml | 8 +-
.../zookeeper/templates/statefulset.yaml | 44 +++++----
.../register-discovery/zookeeper/values.yaml | 25 +++--
18 files changed, 306 insertions(+), 320 deletions(-)
diff --git a/manifests/addons/gen.sh b/manifests/addons/gen.sh
index 8becf65a..037a1ab4 100644
--- a/manifests/addons/gen.sh
+++ b/manifests/addons/gen.sh
@@ -24,58 +24,16 @@ set -eux
# script set up the plain text rendered
KUBERNETES=${WORKDIR}/../kubernetes
-DASHBOARDS=${WORKDIR}
mkdir -p "${KUBERNETES}"
-kubectl delete ns dubbo-system && kubectl create ns dubbo-system
-
-
-# Set up zookeeper
-helm template zookeeper zookeeper \
- --namespace dubbo-system \
- --version 11.1.6 \
- --repo https://charts.bitnami.com/bitnami \
- -f "${WORKDIR}/values-zookeeper.yaml" \
- > "${KUBERNETES}/zookeeper.yaml"
-
+kubectl create ns dubbo-system
+if [ $? -ne 0 ];then
+ kubectl delete ns dubbo-system ; kubectl create ns dubbo-system
+fi
# Set up prometheus
helm template prometheus prometheus \
--namespace dubbo-system \
- --version 20.0.2 \
+ --version 27.5.1 \
--repo https://prometheus-community.github.io/helm-charts \
- -f "${WORKDIR}/values-prometheus.yaml" \
- > "${KUBERNETES}/prometheus.yaml"
-
-
-# Set up grafana
-{
- helm template grafana grafana \
- --namespace dubbo-system \
- --version 6.52.4 \
- --repo https://grafana.github.io/helm-charts \
- -f "${WORKDIR}/values-grafana.yaml" \
-
- echo -e "\n---\n"
-
- kubectl create configmap -n dubbo-system admin-extra-dashboards \
- --dry-run=client -oyaml \
-
--from-file=extra-dashboard.json="${DASHBOARDS}/dashboards/external-dashboard.json"
-} > "${KUBERNETES}/grafana.yaml"
-
-
-# Set up skywalking
-helm template skywalking skywalking \
- --namespace dubbo-system \
- --version 4.3.0 \
- --repo https://apache.jfrog.io/artifactory/skywalking-helm \
- -f "${WORKDIR}/values-skywalking.yaml" \
- > "${KUBERNETES}/skywalking.yaml"
-
-
-# Set up zipkin
-helm template zipkin zipkin \
- --namespace dubbo-system \
- --version 0.1.2 \
- --repo https://zipkin.io/zipkin-helm \
- -f "${WORKDIR}/values-zipkin.yaml" \
- > "${KUBERNETES}/zipkin.yaml"
\ No newline at end of file
+ -f "${WD}/values-prometheus.yaml" \
+ > "${ADDONS}/prometheus.yaml"
\ No newline at end of file
diff --git a/manifests/addons/values-grafana.yaml
b/manifests/addons/values-grafana.yaml
deleted file mode 100644
index 6c78a5d9..00000000
--- a/manifests/addons/values-grafana.yaml
+++ /dev/null
@@ -1,39 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements. See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You 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.
-
-rbac:
- create: false
- pspEnabled: false
- pspUseAppArmor: false
-
-testFramework:
- enabled: false
-
-service:
- port: 3000
-
-datasources:
- datasources.yaml:
- apiVersion: 1
- datasources:
- - name: Prometheus
- type: prometheus
- orgId: 1
- url: http://prometheus:9090
- access: proxy
- isDefault: true
- jsonData:
- timeInterval: 5s
- editable: true
\ No newline at end of file
diff --git a/manifests/addons/values-prometheus.yaml
b/manifests/addons/values-prometheus.yaml
index 27ef5668..ae55a8e2 100644
--- a/manifests/addons/values-prometheus.yaml
+++ b/manifests/addons/values-prometheus.yaml
@@ -15,16 +15,32 @@
alertmanager:
enabled: false
+
prometheus-pushgateway:
enabled: false
+
kube-state-metrics:
enabled: false
+
prometheus-node-exporter:
enabled: false
+
server:
persistentVolume:
enabled: false
service:
servicePort: 9090
+ readinessProbeInitialDelay: 0
+
global:
scrape_interval: 15s
+
+ image:
+ repository: prom/prometheus
+
+ securityContext: null
+
+configmapReload:
+ prometheus:
+ image:
+ repository: ghcr.io/prometheus-operator/prometheus-config-reloader
diff --git a/manifests/addons/values-skywalking.yaml
b/manifests/addons/values-skywalking.yaml
deleted file mode 100644
index 8b2b8966..00000000
--- a/manifests/addons/values-skywalking.yaml
+++ /dev/null
@@ -1,27 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements. See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You 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.
-
-oap:
- image:
- repository: skywalking.docker.scarf.sh/apache/skywalking-oap-cp-server
- tag: 9.3.0
- storageType: elasticsearch
-ui:
- image:
- repository: skywalking.docker.scarf.sh/apache/skywalking-ui
- tag: 9.3.0
-
-elasticsearch:
- enabled: false
\ No newline at end of file
diff --git a/manifests/addons/values-zipkin.yaml
b/manifests/addons/values-zipkin.yaml
deleted file mode 100644
index f7a5bfa0..00000000
--- a/manifests/addons/values-zipkin.yaml
+++ /dev/null
@@ -1,27 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements. See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You 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.
-
-image:
- repository: openzipkin/zipkin-slim
- pullPolicy: IfNotPresent
-
-serviceAccount:
- create: true
-
-ingress:
- enabled: false
-
-autoscaling:
- enabled: false
\ No newline at end of file
diff --git a/manifests/addons/values-zookeeper.yaml
b/manifests/addons/values-zookeeper.yaml
deleted file mode 100644
index 89b007b3..00000000
--- a/manifests/addons/values-zookeeper.yaml
+++ /dev/null
@@ -1,25 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements. See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You 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.
-
-containerSecurityContext:
- enabled: true
-podSecurityContext:
- enabled: true
-serviceAccount:
- create: false
-persistence:
- enabled: false
-pdb:
- create: false
diff --git a/manifests/charts/admin/templates/deployment.yaml
b/manifests/charts/admin/templates/deployment.yaml
index 6054f59b..8a3f6b50 100644
--- a/manifests/charts/admin/templates/deployment.yaml
+++ b/manifests/charts/admin/templates/deployment.yaml
@@ -63,18 +63,18 @@ spec:
volumes:
- name: data
emptyDir: {}
- - name: data
- persistentVolumeClaim:
- claimName: admin-pvc
----
-apiVersion: v1
-kind: PersistentVolumeClaim
-metadata:
- name: admin-pvc
-spec:
- storageClassName: rook-ceph-block
- accessModes:
- - ReadWriteOnce
- resources:
- requests:
- storage: 20Gi
\ No newline at end of file
+{{/* - name: data*/}}
+{{/* persistentVolumeClaim:*/}}
+{{/* claimName: admin-pvc*/}}
+{{/*---*/}}
+{{/*apiVersion: v1*/}}
+{{/*kind: PersistentVolumeClaim*/}}
+{{/*metadata:*/}}
+{{/* name: admin-pvc*/}}
+{{/*spec:*/}}
+{{/* storageClassName: rook-ceph-block*/}}
+{{/* accessModes:*/}}
+{{/* - ReadWriteOnce*/}}
+{{/* resources:*/}}
+{{/* requests:*/}}
+{{/* storage: 20Gi*/}}
\ No newline at end of file
diff --git a/manifests/charts/admin/values.yaml
b/manifests/charts/admin/values.yaml
index 07778386..66dde4e2 100644
--- a/manifests/charts/admin/values.yaml
+++ b/manifests/charts/admin/values.yaml
@@ -23,9 +23,12 @@ _internal_default_values_not_set:
imagePullPolicy: ~
resources:
+ limits:
+ cpu: "512m"
+ memory: "512Mi"
requests:
- cpu: 512m
- memory: 512Mi
+ cpu: "512m"
+ memory: "512Mi"
## Whether to enable the csiDriver.
csiDriver:
diff --git a/manifests/charts/base/templates/ingress-controller.yaml
b/manifests/charts/base/templates/ingress-controller.yaml
new file mode 100644
index 00000000..9b413f80
--- /dev/null
+++ b/manifests/charts/base/templates/ingress-controller.yaml
@@ -0,0 +1,63 @@
+apiVersion: v1
+kind: ServiceAccount
+metadata:
+ name: dubbo-kubernetes-ingress-controller
+---
+apiVersion: rbac.authorization.k8s.io/v1
+kind: ClusterRole
+metadata:
+ name: dubbo-kubernetes-ingress-controller-clusterRole
+rules:
+ - apiGroups: [""]
+ resources: ["services", "secrets"]
+ verbs: ["get", "watch", "list"]
+ - apiGroups: ["extensions", "networking.k8s.io"]
+ resources: ["ingresses"]
+ verbs: ["get", "watch", "list", "update"]
+ - apiGroups: ["networking.k8s.io"]
+ resources: ["ingresses/status"]
+ verbs: ["update"]
+---
+apiVersion: rbac.authorization.k8s.io/v1
+kind: ClusterRoleBinding
+metadata:
+ name: dubbo-kubernetes-ingress-controller-clusterRoleBinding
+roleRef:
+ apiGroup: rbac.authorization.k8s.io
+ kind: ClusterRole
+ name: dubbo-kubernetes-ingress-controller-clusterRole
+subjects:
+ - kind: ServiceAccount
+ name: dubbo-kubernetes-ingress-controller
+ namespace: default
+---
+apiVersion: apps/v1
+kind: Deployment
+metadata:
+ name: dubbo-kubernetes-ingress-controller
+ namespace: default
+ labels:
+ app: ingress-controller
+spec:
+ replicas: 1
+ selector:
+ matchLabels:
+ app: ingress-controller
+ template:
+ metadata:
+ labels:
+ app: ingress-controller
+ spec:
+ hostNetwork: true
+ serviceAccountName: dubbo-kubernetes-ingress-controller
+ containers:
+ - name: dubbo-kubernetes-ingress-controller
+ image: mfordjody/dubbo-kubernetes-ingress-controller:dev
+ imagePullPolicy: Always
+---
+apiVersion: networking.k8s.io/v1
+kind: IngressClass
+metadata:
+ name: dubbo
+spec:
+ controller: "dubbo.io/dubbo-kubernetes-ingress-controller"
\ No newline at end of file
diff --git a/manifests/charts/base/templates/jobs.yaml
b/manifests/charts/base/templates/rook-jobs.yaml
similarity index 78%
rename from manifests/charts/base/templates/jobs.yaml
rename to manifests/charts/base/templates/rook-jobs.yaml
index cbe61379..fb7df4da 100644
--- a/manifests/charts/base/templates/jobs.yaml
+++ b/manifests/charts/base/templates/rook-jobs.yaml
@@ -2,21 +2,22 @@ apiVersion: v1
kind: ConfigMap
metadata:
name: rook-csi-driver-config
+ namespace: {{ .Release.Namespace }}
labels:
app: rook-csi-driver
data:
rook-setup.sh: |-
#!/usr/bin/env bash
-
+
set -ex
-
+
if [ ! -d "rook" ]; then
echo "Pull Rook Project"
git clone https://github.com/rook/rook.git
else
echo "Rook Project Exist,Continue editing..."
fi
-
+
cd rook/deploy/examples/
sed -i 's/ROOK_DISCOVER_DEVICES_INTERVAL:
"60m"/ROOK_DISCOVER_DEVICES_INTERVAL: "60s"/' operator.yaml
sed -i 's/useAllNodes: true/useAllNodes: false/' cluster.yaml
@@ -56,7 +57,7 @@ data:
cpu: "512m"\
memory: "2048Mi"
}' cluster.yaml
-
+
sed -i 's/^ # placement:/ placement:/' cluster.yaml
sed -i '/placement:/,/^[^ ]/ {
/placement:/c\
@@ -98,7 +99,7 @@ data:
values:\
- enabled
}' cluster.yaml
-
+
sed -i 's/^ # nodes:/ nodes:/' cluster.yaml
sed -i '/nodes:/,/^[^ ]/ {
/nodes:/c\
@@ -110,12 +111,12 @@ data:
storeType: bluestore\
journalSizeMB: "4096"
}' cluster.yaml
-
+
kubectl label node osp ceph-mon=enabled
kubectl label node osp ceph-mgr=enabled
kubectl label node osp ceph-mds=enabled
kubectl label node osp ceph-osd=enabled
-
+
kubectl apply -f crds.yaml -f common.yaml -f operator.yaml
kubectl apply -f cluster.yaml -f toolbox.yaml -f
dashboard-external-https.yaml
@@ -153,11 +154,13 @@ data:
# 至少需要 1 个 osd
kubectl apply -f filesystem-test.yaml ; kubectl apply -f
csi/cephfs/storageclass.yaml
+ kubectl apply -f csi/rbd/storageclass-test.yaml
---
apiVersion: batch/v1
kind: Job
metadata:
name: rook-job
+ namespace: {{ .Release.Namespace }}
labels:
app: rook-csi-driver
spec:
@@ -169,63 +172,64 @@ spec:
restartPolicy: OnFailure
serviceAccountName: rook-admin
containers:
- - name: rook-setup
- image: mfordjody/rook-setup:dev
- imagePullPolicy: Always
- command:
- - /bin/sh
- - -c
- - sh /scripts/rook-setup.sh
- volumeMounts:
- - name: scripts
- mountPath: /scripts
+ - name: rook-setup
+ image: mfordjody/rook-setup:dev
+ imagePullPolicy: IfNotPresent
+ command:
+ - /bin/sh
+ - -c
+ - sh /scripts/rook-setup.sh
+ volumeMounts:
+ - name: scripts
+ mountPath: /scripts
volumes:
- - name: scripts
- configMap:
- name: rook-csi-driver-config
- defaultMode: 0755
+ - name: scripts
+ configMap:
+ name: rook-csi-driver-config
+ defaultMode: 0755
---
apiVersion: v1
kind: ServiceAccount
metadata:
name: rook-admin
- namespace: default
+ namespace: {{ .Release.Namespace }}
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
name: rook-admin-role
+ namespace: {{ .Release.Namespace }}
rules:
-- apiGroups: [""]
- resources: ["nodes"]
- verbs: ["get", "list", "watch", "patch", "update"]
-- apiGroups: [""]
- resources: ["pods", "services", "configmaps", "namespaces"]
- verbs: ["*"]
-- apiGroups: ["apps"]
- resources: ["deployments"]
- verbs: ["*"]
-- apiGroups: ["batch"]
- resources: ["jobs"]
- verbs: ["*"]
-- apiGroups: ["apiextensions.k8s.io"]
- resources: ["customresourcedefinitions"]
- verbs: ["*"]
-- apiGroups: ["rbac.authorization.k8s.io"]
- resources: ["clusterroles", "clusterrolebindings"]
- verbs: ["*"]
-- apiGroups: ["rbac.authorization.k8s.io"]
- resources: ["roles", "rolebindings"]
- verbs: ["*"]
-- apiGroups: [""]
- resources: ["serviceaccounts"]
- verbs: ["*"]
-- apiGroups: ["ceph.rook.io"]
- resources: ["cephclusters","cephfilesystemsubvolumegroups","cephfilesystems"]
- verbs: ["*"]
-- apiGroups: ["storage.k8s.io"]
- resources: ["storageclasses"]
- verbs: ["*"]
+ - apiGroups: [""]
+ resources: ["nodes"]
+ verbs: ["get", "list", "watch", "patch", "update"]
+ - apiGroups: [""]
+ resources: ["pods", "services", "configmaps", "namespaces"]
+ verbs: ["*"]
+ - apiGroups: ["apps"]
+ resources: ["deployments"]
+ verbs: ["*"]
+ - apiGroups: ["batch"]
+ resources: ["jobs"]
+ verbs: ["*"]
+ - apiGroups: ["apiextensions.k8s.io"]
+ resources: ["customresourcedefinitions"]
+ verbs: ["*"]
+ - apiGroups: ["rbac.authorization.k8s.io"]
+ resources: ["clusterroles", "clusterrolebindings"]
+ verbs: ["*"]
+ - apiGroups: ["rbac.authorization.k8s.io"]
+ resources: ["roles", "rolebindings"]
+ verbs: ["*"]
+ - apiGroups: [""]
+ resources: ["serviceaccounts"]
+ verbs: ["*"]
+ - apiGroups: ["ceph.rook.io"]
+ resources:
["cephclusters","cephfilesystemsubvolumegroups","cephfilesystems"]
+ verbs: ["*"]
+ - apiGroups: ["storage.k8s.io"]
+ resources: ["storageclasses"]
+ verbs: ["*"]
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRoleBinding
@@ -238,4 +242,4 @@ roleRef:
subjects:
- kind: ServiceAccount
name: rook-admin
- namespace: default
\ No newline at end of file
+ namespace: {{ .Release.Namespace }}
\ No newline at end of file
diff --git a/manifests/charts/base/values.yaml
b/manifests/charts/base/values.yaml
index d14bce2c..aad7acf8 100644
--- a/manifests/charts/base/values.yaml
+++ b/manifests/charts/base/values.yaml
@@ -16,3 +16,52 @@
_internal_default_values_not_set:
global: {}
base: {}
+
+ rook:
+ labelSelector:
+ node: ""
+ mon:
+ limits:
+ cpu: "102m"
+ memory: "256Mi"
+ requests:
+ cpu: "102m"
+ memory: "256Mi"
+ mgr:
+ limits:
+ cpu: "102m"
+ memory: "512Mi"
+ requests:
+ cpu: "102m"
+ memory: "512Mi"
+ mds:
+ limits:
+ cpu: "102m"
+ memory: "256Mi"
+ requests:
+ cpu: "102m"
+ memory: "256Mi"
+ osd:
+ limits:
+ cpu: "512m"
+ memory: "2048Mi"
+ requests:
+ cpu: "512m"
+ memory: "2048Mi"
+
+ nodes:
+ - name: "osp"
+ devices:
+ - name: "nvme0n2"
+ config:
+ storeType: bluestore
+ journalSizeMB: "4096"
+
+ cephfs:
+ resources:
+ limits:
+ cpu: "256m"
+ memory: "512Mi"
+ requests:
+ cpu: "256m"
+ memory: "512Mi"
\ No newline at end of file
diff --git
a/manifests/charts/dubbo-control/register-discovery/nacos/templates/mysql-configmap.yaml
b/manifests/charts/dubbo-control/register-discovery/nacos/templates/mysql-configmap.yaml
index cc5911a6..51eeab2b 100644
---
a/manifests/charts/dubbo-control/register-discovery/nacos/templates/mysql-configmap.yaml
+++
b/manifests/charts/dubbo-control/register-discovery/nacos/templates/mysql-configmap.yaml
@@ -1,6 +1,5 @@
# mysql -unacos -pnacos nacos < mysql-schema.sql
-{{- $nacos := .Values -}}
-{{- $ncs := .Values.nacos }}
+{{ $nacos := .Values }}
{{- if eq $nacos.storage.type "mysql" }}
apiVersion: v1
kind: ConfigMap
diff --git
a/manifests/charts/dubbo-control/register-discovery/nacos/templates/mysql-service.yaml
b/manifests/charts/dubbo-control/register-discovery/nacos/templates/mysql-service.yaml
index c898776d..86c1d7e0 100644
---
a/manifests/charts/dubbo-control/register-discovery/nacos/templates/mysql-service.yaml
+++
b/manifests/charts/dubbo-control/register-discovery/nacos/templates/mysql-service.yaml
@@ -1,4 +1,4 @@
-{{- $nacos := .Values -}}
+{{ $nacos := .Values }}
{{- if eq $nacos.storage.type "mysql" }}
apiVersion: v1
kind: Service
@@ -21,10 +21,7 @@ spec:
protocol: TCP
selector:
app: nacos-mysql
-{{- end -}}
---
-{{- $nacos := .Values -}}
-{{- if eq $nacos.storage.type "mysql" }}
apiVersion: v1
kind: Service
metadata:
@@ -47,4 +44,4 @@ spec:
protocol: TCP
selector:
app: nacos-mysql
-{{- end -}}
+{{- end -}}
\ No newline at end of file
diff --git
a/manifests/charts/dubbo-control/register-discovery/nacos/templates/mysql-statefulset.yaml
b/manifests/charts/dubbo-control/register-discovery/nacos/templates/mysql-statefulset.yaml
index 77c03f04..3a8eb90d 100644
---
a/manifests/charts/dubbo-control/register-discovery/nacos/templates/mysql-statefulset.yaml
+++
b/manifests/charts/dubbo-control/register-discovery/nacos/templates/mysql-statefulset.yaml
@@ -1,4 +1,4 @@
-{{- $nacos := .Values -}}
+{{ $nacos := .Values }}
{{- if eq $nacos.storage.type "mysql" }}
apiVersion: apps/v1
kind: StatefulSet
@@ -71,25 +71,25 @@ spec:
configMap:
name: nacos-table-config
defaultMode: 0755
- volumeClaimTemplates:
- - metadata:
- name: data
- spec:
- accessModes:
- - ReadWriteOnce
- resources:
- requests:
- storage: 5Gi
{{- end -}}
----
-apiVersion: v1
-kind: PersistentVolumeClaim
-metadata:
- name: mysql-pvc
-spec:
- storageClassName: rook-ceph-block
- accessModes:
- - ReadWriteOnce
- resources:
- requests:
- storage: 20Gi
\ No newline at end of file
+{{/* volumeClaimTemplates:*/}}
+{{/* - metadata:*/}}
+{{/* name: data*/}}
+{{/* spec:*/}}
+{{/* accessModes:*/}}
+{{/* - ReadWriteOnce*/}}
+{{/* resources:*/}}
+{{/* requests:*/}}
+{{/* storage: 5Gi*/}}
+{{/*---*/}}
+{{/*apiVersion: v1*/}}
+{{/*kind: PersistentVolumeClaim*/}}
+{{/*metadata:*/}}
+{{/* name: mysql-pvc*/}}
+{{/*spec:*/}}
+{{/* storageClassName: rook-ceph-block*/}}
+{{/* accessModes:*/}}
+{{/* - ReadWriteOnce*/}}
+{{/* resources:*/}}
+{{/* requests:*/}}
+{{/* storage: 20Gi*/}}
diff --git
a/manifests/charts/dubbo-control/register-discovery/nacos/templates/statefulset.yaml
b/manifests/charts/dubbo-control/register-discovery/nacos/templates/statefulset.yaml
index 3533a097..fa91a21b 100644
---
a/manifests/charts/dubbo-control/register-discovery/nacos/templates/statefulset.yaml
+++
b/manifests/charts/dubbo-control/register-discovery/nacos/templates/statefulset.yaml
@@ -47,7 +47,9 @@ spec:
{{- end }}
containers:
- name: nacos
- image: nacos/nacos-server
+ {{- if contains "/" $nacos.image }}
+ image: {{ $nacos.image }}
+ {{- end }}
imagePullPolicy: {{ $nacos.imagePullPolicy }}
ports:
- name: http
@@ -123,24 +125,24 @@ spec:
volumes:
- name: data
emptyDir: {}
- volumeClaimTemplates:
- - metadata:
- name: data
- spec:
- accessModes:
- - ReadWriteOnce
- resources:
- requests:
- storage: 5Gi
----
-apiVersion: v1
-kind: PersistentVolumeClaim
-metadata:
- name: nacos-pvc
-spec:
- storageClassName: rook-ceph-block
- accessModes:
- - ReadWriteOnce
- resources:
- requests:
- storage: 20Gi
\ No newline at end of file
+{{/* volumeClaimTemplates:*/}}
+{{/* - metadata:*/}}
+{{/* name: data*/}}
+{{/* spec:*/}}
+{{/* accessModes:*/}}
+{{/* - ReadWriteOnce*/}}
+{{/* resources:*/}}
+{{/* requests:*/}}
+{{/* storage: 5Gi*/}}
+{{/*---*/}}
+{{/*apiVersion: v1*/}}
+{{/*kind: PersistentVolumeClaim*/}}
+{{/*metadata:*/}}
+{{/* name: nacos-pvc*/}}
+{{/*spec:*/}}
+{{/* storageClassName: rook-ceph-block*/}}
+{{/* accessModes:*/}}
+{{/* - ReadWriteOnce*/}}
+{{/* resources:*/}}
+{{/* requests:*/}}
+{{/* storage: 20Gi*/}}
\ No newline at end of file
diff --git
a/manifests/charts/dubbo-control/register-discovery/nacos/values.yaml
b/manifests/charts/dubbo-control/register-discovery/nacos/values.yaml
index 86173768..ee1b8408 100644
--- a/manifests/charts/dubbo-control/register-discovery/nacos/values.yaml
+++ b/manifests/charts/dubbo-control/register-discovery/nacos/values.yaml
@@ -20,16 +20,14 @@ _internal_default_values_not_set:
mode: "cluster"
## Number of replicas for the Deployment.
replicas: 1
-
+ # Deploy the required container images.
+ image: nacos/nacos-server
+ # The size of application resources required for deployment.
resources:
requests:
cpu: 250m
memory: 256Mi
- ## Whether to enable the csiDriver.
- csiDriver:
- enabled: false
-
storage:
# Specifies the storage type (embedded, mysql, etc.).
type: "mysql"
diff --git
a/manifests/charts/dubbo-control/register-discovery/zookeeper/templates/statefulset.yaml
b/manifests/charts/dubbo-control/register-discovery/zookeeper/templates/statefulset.yaml
index 3a8d902f..265f1e2a 100644
---
a/manifests/charts/dubbo-control/register-discovery/zookeeper/templates/statefulset.yaml
+++
b/manifests/charts/dubbo-control/register-discovery/zookeeper/templates/statefulset.yaml
@@ -34,28 +34,30 @@ spec:
spec:
containers:
- name: zookeeper
- image: zookeeper
- imagePullPolicy: {{ $zookeeper.imagePullPolicy }}
+ {{- if contains "/" $zookeeper.image }}
+ image: {{ $zookeeper.image }}
+ {{- end }}
+ imagePullPolicy: IfNotPresent
env:
- # The number of milliseconds of each tick
- - name: TICK_TIME
- value: "2000"
- # The number of ticks that the initial
- # synchronization phase can take
- - name: INIT_LIMIT
- value: "10"
- # The number of ticks that can pass between
- # sending a request and getting an acknowledgement
- - name: SYNC_LIMIT
- value: "5"
- # the directory where the snapshot is stored.
- # do not use /tmp for storage, /tmp here is just
- # example sakes.
- - name: DATA_LOG_DIR
- value: ''
- # the port at which the clients will connect
- - name: PORT_NUMBER
- value: "2181"
+ # The number of milliseconds of each tick
+ - name: TICK_TIME
+ value: {{ $zookeeper.tickTime | quote }}
+ # The number of ticks that the initial
+ # synchronization phase can take
+ - name: INIT_LIMIT
+ value: {{ $zookeeper.initLimit | quote }}
+ # The number of ticks that can pass between
+ # sending a request and getting an acknowledgement
+ - name: SYNC_LIMIT
+ value: {{ $zookeeper.syncLimit | quote }}
+ # the directory where the snapshot is stored.
+ # do not use /tmp for storage, /tmp here is just
+ # example sakes.
+ - name: DATA_LOG_DIR
+ value: {{ $zoo.dataLogDir | quote }}
+ # the port at which the clients will connect
+ - name: PORT_NUMBER
+ value: {{ $zookeeper.portNumber | quote }}
resources:
{{ toYaml $zookeeper.resources | trim | indent 10 }}
ports:
diff --git
a/manifests/charts/dubbo-control/register-discovery/zookeeper/values.yaml
b/manifests/charts/dubbo-control/register-discovery/zookeeper/values.yaml
index 26a3aba6..6e6f0b56 100644
--- a/manifests/charts/dubbo-control/register-discovery/zookeeper/values.yaml
+++ b/manifests/charts/dubbo-control/register-discovery/zookeeper/values.yaml
@@ -14,16 +14,29 @@
# limitations under the License.
_internal_default_values_not_set:
- ## Whether to enable the zookeeper.
+ # Whether to enable the zookeeper.
enabled: false
- ## Number of replicas for the Deployment.
+ # Number of replicas for the Deployment.
replicas: 1
-
+ # Deploy the required container images.
+ image: docker.io/library/zookeeper
+ # The size of application resources required for deployment.
resources:
requests:
cpu: 250m
memory: 256Mi
+ # The number of milliseconds of each tick
+ tickTime: 2000
+ # The number of ticks that the initial
+ # synchronization phase can take
+ initLimit: 10
+ # The number of ticks that can pass between
+ # sending a request and getting an acknowledgement
+ syncLimit: 5
+ # the directory where the snapshot is stored.
+ # do not use /tmp for storage, /tmp here is just
+ # example sakes.
+ dataLogDir: ""
+ # the port at which the clients will connect
+ portNumber: 2181
- ## Whether to enable the csiDriver.
- csiDriver:
- enabled: false