Skip to content

Commit 3c8d664

Browse files
feat: process migration phase2 (#3915)
1 parent 0502e3a commit 3c8d664

File tree

2 files changed

+35
-9
lines changed

2 files changed

+35
-9
lines changed

charts/camunda-platform-8.8/templates/core/process-migration-configmap.yaml

Lines changed: 21 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,16 +2,35 @@
22
apiVersion: v1
33
kind: ConfigMap
44
metadata:
5-
name: {{ include "identity.fullname" . }}-migration-configuration
5+
name: {{ include "core.fullname" . }}-process-migration-configuration
66
data:
77
application.yaml: |
88
spring:
99
profiles:
1010
active: process-migration
11+
{{- if .Values.global.elasticsearch.enabled }}
1112
camunda:
1213
database:
13-
username: ${VALUES_DATABASE_USERNAME:}
14+
connect:
15+
cluster-name: elasticsearch
16+
cluster-type: elasticsearch
17+
url: {{ include "camundaPlatform.elasticsearchURL" . | quote }}
18+
{{- if and .Values.global.elasticsearch.auth.username .Values.global.elasticsearch.auth.password }}
19+
username: {{ .Values.global.elasticsearch.auth.username }}
1420
password: ${VALUES_DATABASE_PASSWORD:}
21+
{{- end }}
22+
{{- else }}
23+
camunda:
24+
database:
25+
connect:
26+
cluster-name: opensearch
27+
cluster-type: opensearch
28+
url: {{ include "camundaPlatform.opensearchURL" . | quote }}
29+
{{- if and .Values.global.opensearch.auth.username .Values.global.opensearch.auth.password }}
30+
username: {{ .Values.global.opensearch.auth.username }}
31+
password: ${VALUES_DATABASE_PASSWORD:}
32+
{{- end }}
33+
{{- end }}
1534
migration:
1635
process:
1736
batch-size: 5

charts/camunda-platform-8.8/templates/core/process-migration-job.yaml

Lines changed: 14 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,19 @@ spec:
1717
{{- if .Values.core.podSecurityContext }}
1818
securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" $.Values.core.podSecurityContext "context" $) | nindent 8 }}
1919
{{- end }}
20+
initContainers:
21+
- name: wait-for-core
22+
{{- if .Values.core.containerSecurityContext }}
23+
securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" $.Values.core.containerSecurityContext "context" $) | nindent 12 }}
24+
{{- end }}
25+
image: curlimages/curl:8.15.0
26+
command:
27+
- sh
28+
- -c
29+
- |
30+
until curl -sf http://{{ include "core.fullname" . }}-gateway:{{ .Values.core.service.managementPort }}{{ include "camundaPlatform.joinpath" (list .Values.core.contextPath .Values.core.readinessProbe.probePath) }}; do
31+
echo "waiting for Orchestration Cluster"; sleep 5;
32+
done
2033
containers:
2134
- name: camunda-migration
2235
image: {{ include "camundaPlatform.imageByParams" (dict "base" .Values.global "overlay" .Values.core) }}
@@ -26,25 +39,19 @@ spec:
2639
{{- end }}
2740
env:
2841
{{- if and .Values.global.elasticsearch.external .Values.global.elasticsearch.auth.password -}}
29-
- name: VALUES_DATABASE_USERNAME
30-
value: {{ .Values.global.elasticsearch.auth.username }}
3142
- name: VALUES_DATABASE_PASSWORD
3243
valueFrom:
3344
secretKeyRef:
3445
name: {{ include "camundaPlatform.fullname" . }}-elasticsearch
3546
key: {{ .Values.global.elasticsearch.auth.existingSecretKey }}
3647
{{- end }}
37-
{{- if and .Values.global.opensearch.external .Values.global.opensearch.auth.password -}}
38-
- name: VALUES_DATABASE_USERNAME
39-
value: {{ .Values.global.opensearch.auth.username }}
48+
{{- if and .Values.global.opensearch.enabled .Values.global.opensearch.auth.password -}}
4049
- name: VALUES_DATABASE_PASSWORD
4150
valueFrom:
4251
secretKeyRef:
4352
name: {{ include "camundaPlatform.fullname" . }}-opensearch
4453
key: {{ .Values.global.opensearch.auth.existingSecretKey }}
4554
{{- end }}
46-
- name: JAVA_TOOL_OPTIONS
47-
value: -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=/usr/local/camunda/data -XX:ErrorFile=/usr/local/camunda/data/zeebe_error%p.log -XX:+ExitOnOutOfMemoryError -agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=*:5005
4855
command:
4956
- /usr/local/camunda/bin/process-migration
5057
resources:

0 commit comments

Comments
 (0)