[Modeling] Use common secret template for mariadb root password
Remove hardcoded root password from the modeling chart.
Because of huge number of issues in modeling docker image
(see onap-discuss for details) I don't want to touch it.
That's why I just made an awful hack to concatenate DB
username and password before the entrypoint script.
Please keep in mind that this eliminates only hardcoded
root password but there is plenty of other credentials that
are boiled into container image (DB, SDC, VCF-REDIS(!) etc).
Issue-ID: OOM-2286
Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com>
Change-Id: Id85a03ec7f55885b606179d10e8b6528c6cb6947
diff --git a/kubernetes/modeling/charts/modeling-etsicatalog/values.yaml b/kubernetes/modeling/charts/modeling-etsicatalog/values.yaml
index 2244d5f..bb5a76b 100644
--- a/kubernetes/modeling/charts/modeling-etsicatalog/values.yaml
+++ b/kubernetes/modeling/charts/modeling-etsicatalog/values.yaml
@@ -32,16 +32,23 @@
mountPath: /dockerdata-nfs
#################################################################
+# Secrets metaconfig
+#################################################################
+secrets:
+ - uid: "db-root-pass"
+ externalSecret: '{{- include "common.mariadb.secret.rootPassSecretName" (dict "dot" . "chartName" (index .Values "mariadb-galera" "nameOverride")) }}'
+ type: password
+
+#################################################################
# Dependencies configuration
#################################################################
mariadb-galera:
- config:
- mariadbRootPassword: secretpassword
nameOverride: modeling-mariadb
service:
name: modeling-db
portName: modeling-db
+ internalPort: 3306
nfsprovisionerPrefix: modeling
persistence:
mountSubPath: modeling/data
@@ -64,12 +71,6 @@
# flag to enable debugging - application support required
debugEnabled: false
-# application configuration
-config:
- dbServiceName: modeling-db
- dbPort: 3306
- dbUser: root
-
# default number of instances
replicaCount: 1