X-Git-Url: https://gerrit.onap.org/r/gitweb?a=blobdiff_plain;f=kubernetes%2Fcommon%2Fmariadb-init%2Fvalues.yaml;h=e0ba28266ab19bb793d4d16229b4161828d49147;hb=060bc378e32c2ffba34f890c53cc359eb9ee64d0;hp=095ff62ddf9c3959f62d25f90686f8b3f5162253;hpb=525447ad64582c9d8a94542cc32e89c9986d864d;p=oom.git diff --git a/kubernetes/common/mariadb-init/values.yaml b/kubernetes/common/mariadb-init/values.yaml index 095ff62ddf..e0ba28266a 100644 --- a/kubernetes/common/mariadb-init/values.yaml +++ b/kubernetes/common/mariadb-init/values.yaml @@ -16,29 +16,80 @@ # Global configuration defaults. ################################################################# global: - repository: nexus3.onap.org:10001 - readinessRepository: oomk8s - readinessImage: readiness-check:2.0.2 mariadbGalera: nameOverride: mariadb-galera servicePort: 3306 # set these two values if you want to access an 'out of ONAP' mariadb - userRootSecret: default - userRootSecretKey: db-root-password + # userRootPassword: some-password + # userRootSecret: some-secret-name + # userRootSecretKey: password + +################################################################# +# Secrets metaconfig +################################################################# +secrets: + - uid: root-password + type: password + externalSecret: '{{ tpl (ternary (default "" .Values.mariadbGalera.userRootSecret) (default (include "mariadbInit.mariadbClusterSecret" .) .Values.global.mariadbGalera.userRootSecret) (not (empty (default "" .Values.mariadbGalera.serviceName)))) . }}' + password: '{{ tpl (ternary (default "" .Values.mariadbGalera.userRootPassword) (default "" .Values.global.mariadbGalera.userRootPassword) (not (empty (default "" .Values.mariadbGalera.serviceName)))) . }}' + - uid: '{{ .Values.config.mysqlDatabase }}' + type: basicAuth + externalSecret: '{{ tpl (default "" .Values.config.userCredentialsExternalSecret) . }}' + login: '{{ .Values.config.userName }}' + password: '{{ .Values.config.userPassword }}' + passwordPolicy: required ################################################################# # Application configuration defaults. ################################################################# -image: mariadb:10.1.38 pullPolicy: IfNotPresent +# These two values are used to supply commands that are run after the DB is created. +# Components using the shared DB can either pass a string which has a set of commands +# or a config map that contains a shell script. If both are specified only the config +# map will be executed. For reference, please see the VID components for config map +dbScript: "" +dbScriptConfigMap: "" + # Set it if you want to change the name of the different components # nameOverride: +mariadbGalera: {} +# serviceName: some-name +# containerName: some-name +# servicePort: 3306 +# userRootPassword: some-password +# userRootSecret: some-secret-name +# userRootSecretKey: password + +# These are default settings, required for a chart compilation with "local" cluster +# setting. These values need to be overwritten in the component's values.yaml, e.g. +# global: +# mariadbGalera: &mariadbGalera +# #This flag allows SO to instantiate its own mariadb-galera cluster +# localCluster: true +# service: nbi-galera +# internalPort: 3306 +# nameOverride: nbi-galera +# mariadb-init: +# mariadb-galera: +# nameOverride: nbi-galera +# service: +# internalPort: 3306 +mariadb-galera: + service: + internalPort: 3306 + nameOverride: mariadb-galera + mariadbOperator: + galera: + enabled: false + config: userPassword: Ci@shsOd3pky1Vji userName: u5WZ1GMSIS1wHZF + # set this value if you would like to use external secret instead of providing a password + # userCredentialsExternalsecret: some-secret-name mysqlDatabase: ynsaUCru6mUNwGal mysqlAdditionalDatabases: {} # add addtional dabases @@ -48,9 +99,11 @@ config: # dbOne: # user: one # password: pwd1 + # externalSecret: some-secret-name # dbTwo: # user: two # password: pwd2 + # externalSecret: some-secret-name config_map: default nodeSelector: {} @@ -72,16 +125,40 @@ flavor: small resources: small: limits: - cpu: 100m - memory: 500Mi + cpu: "100m" + memory: "0.5Gi" requests: - cpu: 10m - memory: 10Mi + cpu: "10m" + memory: "0.01Gi" large: limits: - cpu: 200m - memory: 500Mi + cpu: "200m" + memory: "0.5Gi" requests: - cpu: 20m - memory: 20Mi + cpu: "20m" + memory: "0.02Gi" unlimited: {} + +#Pods Service Account +serviceAccount: + nameOverride: mariadb-init + roles: + - read + +wait_for_job_container: + containers: + - '{{ include "common.name" . }}' + +readinessCheck: + wait_for_global_operator: + pods: + - '{{ .Values.global.mariadbGalera.nameOverride }}-0' + wait_for_local_operator: + pods: + - '{{ index .Values "mariadb-galera" "nameOverride" }}-0' + wait_for_global: + apps: + - '{{ include "common.mariadbAppName" . }}' + wait_for_local: + apps: + - '{{ include "common.mariadbAppName" . }}'