aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKrzysztof Opasiak <k.opasiak@samsung.com>2020-05-21 14:50:51 +0000
committerGerrit Code Review <gerrit@onap.org>2020-05-21 14:50:51 +0000
commit3a24f57b37bac7817dbdffdeee9856f92b4d2829 (patch)
treef4f8fce0930ec7e8e1407dcabebea9dee9dd8810
parenta83b521222ca20d203a754e25858eb23e45c9b69 (diff)
parent91566f00ca5ad9d76ff658f05fc8596ab481287a (diff)
Merge "Naming micro-service - Helm chart values updates."
-rw-r--r--kubernetes/common/network-name-gen/templates/deployment.yaml11
-rw-r--r--kubernetes/common/network-name-gen/values.yaml9
2 files changed, 17 insertions, 3 deletions
diff --git a/kubernetes/common/network-name-gen/templates/deployment.yaml b/kubernetes/common/network-name-gen/templates/deployment.yaml
index 3e9e849052..b9550c7666 100644
--- a/kubernetes/common/network-name-gen/templates/deployment.yaml
+++ b/kubernetes/common/network-name-gen/templates/deployment.yaml
@@ -57,6 +57,11 @@ spec:
name: {{ include "common.name" . }}-readiness
containers:
- name: {{ include "common.name" . }}
+ command:
+ - bash
+ args:
+ - '-c'
+ - 'export POL_BASIC_AUTH=`echo -n $POL_BASIC_AUTH_USER:$POL_BASIC_AUTH_PASSWORD | base64`; /startService.sh'
image: "{{ include "common.repository" . }}/{{ .Values.image }}"
imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
env:
@@ -70,8 +75,10 @@ spec:
value: jdbc:mysql://{{ include "common.mariadbService" . }}:{{ include "common.mariadbPort" . }}/{{ index .Values "mariadb-galera" "config" "mysqlDatabase" }}
- name: POL_CLIENT_AUTH
value: "{{ .Values.config.polClientAuth }}"
- - name: POL_BASIC_AUTH
- value: "{{ .Values.config.polBasicAuth }}"
+ - name: POL_BASIC_AUTH_USER
+ {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "pol-basic-auth-secret" "key" "login") | indent 10}}
+ - name: POL_BASIC_AUTH_PASSWORD
+ {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "pol-basic-auth-secret" "key" "password") | indent 10}}
- name: POL_URL
value: "{{ .Values.config.polUrl }}"
- name: POL_ENV
diff --git a/kubernetes/common/network-name-gen/values.yaml b/kubernetes/common/network-name-gen/values.yaml
index 10a5bceb1e..81c596c6c9 100644
--- a/kubernetes/common/network-name-gen/values.yaml
+++ b/kubernetes/common/network-name-gen/values.yaml
@@ -49,6 +49,12 @@ secrets:
externalSecret: '{{ tpl (default "" .Values.config.db.userCredentialsExternalSecret) . }}'
login: '{{ .Values.config.db.userName }}'
password: '{{ .Values.config.db.userPassword }}'
+ - uid: pol-basic-auth-secret
+ name: '{{ include "common.release" . }}-pol-basic-auth-secret'
+ type: basicAuth
+ externalSecret: '{{ tpl (default "" .Values.config.polBasicAuthSecret) . }}'
+ login: '{{ .Values.config.polBasicAuthUser }}'
+ password: '{{ .Values.config.polBasicAuthPassword }}'
# sub-chart config
mariadb-galera:
@@ -84,7 +90,8 @@ config:
# userCredentialsExternalSecret: some-secret
springProfile: live
polClientAuth: cHl0aG9uOnRlc3Q=
- polBasicAuth: dGVzdHBkcDphbHBoYTEyMw==
+ polBasicAuthUser: healthcheck
+ polBasicAuthPassword: zb!XztG34
polUrl: https://policy-xacml-pdp:6969/policy/pdpx/v1/decision
polEnv: TEST
polReqId: xx