mirror of
https://github.com/wahyd4/charts.git
synced 2026-08-09 05:06:29 +10:00
[bitnami/mongodb] Set dynamic port on mongodb-exporter uri (#14041)
Signed-off-by: Miguel Ruiz <miruiz@vmware.com> Signed-off-by: Miguel Ruiz <miruiz@vmware.com>
This commit is contained in:
@@ -26,4 +26,4 @@ name: mongodb
|
||||
sources:
|
||||
- https://github.com/bitnami/containers/tree/main/bitnami/mongodb
|
||||
- https://mongodb.org
|
||||
version: 13.6.1
|
||||
version: 13.6.2
|
||||
|
||||
@@ -419,10 +419,10 @@ Validate values of MongoDB® exporter URI string - auth.enabled and/or tls.en
|
||||
{{- $uriTlsArgs := ternary "tls=true&tlsCertificateKeyFile=/certs/mongodb.pem&tlsCAFile=/certs/mongodb-ca-cert" "" .Values.tls.enabled -}}
|
||||
{{- if .Values.metrics.username }}
|
||||
{{- $uriAuth := ternary "$(echo $MONGODB_METRICS_USERNAME | sed -r \"s/@/%40/g;s/:/%3A/g\"):$(echo $MONGODB_METRICS_PASSWORD | sed -r \"s/@/%40/g;s/:/%3A/g\")@" "" .Values.auth.enabled -}}
|
||||
{{- printf "mongodb://%slocalhost:27017/admin?%s" $uriAuth $uriTlsArgs -}}
|
||||
{{- printf "mongodb://%slocalhost:%d/admin?%s" $uriAuth (int .Values.containerPorts.mongodb) $uriTlsArgs -}}
|
||||
{{- else -}}
|
||||
{{- $uriAuth := ternary "$MONGODB_ROOT_USER:$(echo $MONGODB_ROOT_PASSWORD | sed -r \"s/@/%40/g;s/:/%3A/g\")@" "" .Values.auth.enabled -}}
|
||||
{{- printf "mongodb://%slocalhost:27017/admin?%s" $uriAuth $uriTlsArgs -}}
|
||||
{{- printf "mongodb://%slocalhost:%d/admin?%s" $uriAuth (int .Values.containerPorts.mongodb) $uriTlsArgs -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user