diff --git a/tools/kubeblocks_helm/pika/templates/clusterdefinition.yaml b/tools/kubeblocks_helm/pika/templates/clusterdefinition.yaml index 537b80453f..80358eaf0a 100644 --- a/tools/kubeblocks_helm/pika/templates/clusterdefinition.yaml +++ b/tools/kubeblocks_helm/pika/templates/clusterdefinition.yaml @@ -70,6 +70,13 @@ spec: args: - "-c" - "/script/admin.sh --register-server;tail -f /dev/null" + lifecycle: + preStop: + exec: + command: + - "/bin/bash" + - "-c" + - "/script/admin.sh --remove-server" - name: etcd workloadType: Stateful characterType: etcd