File tree 2 files changed +9
-3
lines changed
2 files changed +9
-3
lines changed Original file line number Diff line number Diff line change 1
1
{{- $nameSpace := include "lowcoder.namespace" . -}}
2
2
{{- $mongoUser := (and .Values.mongodb.auth.usernames (first .Values.mongodb.auth.usernames)) | default "" -}}
3
3
{{- $mongoPassword := (and .Values.mongodb.auth.passwords (first .Values.mongodb.auth.passwords)) | default "" -}}
4
+ {{- $mongoProtocol := ternary "mongodb+srv" "mongodb" .Values.mongodb.useSrv -}}
5
+ {{- $mongoSSL := ternary "true" "false" .Values.mongodb.useSSL -}}
4
6
{{- $lowcoderDatabase := first .Values.mongodb.auth.databases -}}
5
7
{{- $mongoSecret := lookup "v1" "Secret" $nameSpace .Values.mongodb.auth.existingSecret | default dict -}}
6
8
{{- $mongoSecretPassword := (index ($mongoSecret.data | default dict) "password" | default "" | b64dec) -}}
@@ -20,9 +22,9 @@ metadata:
20
22
{{- end }}
21
23
stringData :
22
24
{{- if .Values.mongodb.enabled }}
23
- LOWCODER_MONGODB_URL : " mongodb ://{{ $mongoUser }}:{{ $mongoPassword }}@{{ $mongoServicename }}.{{ $nameSpace }}.svc.cluster.local/{{ $lowcoderDatabase }}?retryWrites=true&ssl=false"
25
+ LOWCODER_MONGODB_URL : " {{ $mongoProtocol }} ://{{ $mongoUser }}:{{ $mongoPassword }}@{{ $mongoServicename }}.{{ $nameSpace }}.svc.cluster.local/{{ $lowcoderDatabase }}?retryWrites=true&ssl=false"
24
26
{{- else }}
25
- LOWCODER_MONGODB_URL : " mongodb ://{{ $mongoUser }}:{{ $mongoSecretPassword }}@{{ $externalUrl }}/{{ $lowcoderDatabase }}?retryWrites=true&ssl=false "
27
+ LOWCODER_MONGODB_URL : " {{ $mongoProtocol }} ://{{ $mongoUser }}:{{ $mongoSecretPassword }}@{{ $externalUrl }}/{{ $lowcoderDatabase }}?retryWrites=true&ssl={{ $mongoSSL }} "
26
28
{{- end }}
27
29
LOWCODER_DB_ENCRYPTION_PASSWORD : {{ .Values.global.config.encryption.password | default "lowcoder.org" | quote }}
28
30
LOWCODER_DB_ENCRYPTION_SALT : {{ .Values.global.config.encryption.salt | default "lowcoder.org" | quote }}
Original file line number Diff line number Diff line change @@ -63,10 +63,14 @@ redis:
63
63
# Find out more about configuration options at: https://github.com/bitnami/charts/tree/main/bitnami/mongodb/#parameters
64
64
#
65
65
mongodb :
66
- # externalUrl:
67
66
enabled : true
68
67
service :
69
68
nameOverride : lowcoder-mongodb
69
+ # externalUrl:
70
+ # if set to true, will use mongodb+srv:// as a prefix in mongo connection string
71
+ useSrv : false
72
+ # if set to true, will use SSL in mongo connection string; Only considered if using external mongodb
73
+ useSSL : false
70
74
auth :
71
75
rootUser : root
72
76
rootPassword : secret
You can’t perform that action at this time.
0 commit comments