diff options
Diffstat (limited to 'kubernetes/cps')
-rwxr-xr-x | kubernetes/cps/resources/config/application-helm.yml (renamed from kubernetes/cps/resources/config/application.yml) | 15 | ||||
-rwxr-xr-x | kubernetes/cps/templates/deployment.yaml | 14 | ||||
-rwxr-xr-x | kubernetes/cps/values.yaml | 10 |
3 files changed, 31 insertions, 8 deletions
diff --git a/kubernetes/cps/resources/config/application.yml b/kubernetes/cps/resources/config/application-helm.yml index 3fa080e395..5f19007231 100755 --- a/kubernetes/cps/resources/config/application.yml +++ b/kubernetes/cps/resources/config/application-helm.yml @@ -50,7 +50,14 @@ spring: liquibase: change-log: classpath:changelog/changelog-master.yaml - labels: ${LIQUIBASE_LABELS} + labels: {{ .Values.config.liquibaseLabels }} + +security: + # comma-separated uri patterns which do not require authorization + permit-uri: /manage/health/**,/manage/info,/swagger-ui/**,/swagger-resources/**,/v3/api-docs + auth: + username: ${CPS_USERNAME} + password: ${CPS_PASSWORD} # Actuator management: @@ -72,3 +79,9 @@ logging: level: org: springframework: {{ .Values.logging.level }} + +{{- if .Values.config.additional }} +{{ toYaml .Values.config.additional | nindent 2 }} +{{- end }} + +# Last empty line is required otherwise the last property will be missing from application.yml file in the pod. diff --git a/kubernetes/cps/templates/deployment.yaml b/kubernetes/cps/templates/deployment.yaml index 59062cc0f8..61877c38a0 100755 --- a/kubernetes/cps/templates/deployment.yaml +++ b/kubernetes/cps/templates/deployment.yaml @@ -43,6 +43,10 @@ spec: {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "pg-user-creds" "key" "password") | indent 12 }} - name: LIQUIBASE_LABELS value: {{ .Values.config.liquibaseLabels }} + - name: CPS_USERNAME + {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "app-user-creds" "key" "login") | indent 12 }} + - name: CPS_PASSWORD + {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "app-user-creds" "key" "password") | indent 12 }} volumeMounts: - mountPath: /config-input name: init-data-input @@ -71,10 +75,8 @@ spec: initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }} periodSeconds: {{ .Values.readiness.periodSeconds }} env: - - name: CPS_USERNAME - {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "app-user-creds" "key" "login") | indent 12 }} - - name: CPS_PASSWORD - {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "app-user-creds" "key" "password") | indent 12 }} + - name: SPRING_PROFILES_ACTIVE + value: {{ .Values.config.spring.profile }} resources: {{ include "common.resources" . | nindent 10 }} {{- if .Values.nodeSelector }} nodeSelector: {{ toYaml .Values.nodeSelector | nindent 12 }} @@ -83,8 +85,8 @@ spec: affinity: {{ toYaml .Values.affinity | nindent 12 }} {{- end }} volumeMounts: - - mountPath: /app/resources/application.yml - subPath: application.yml + - mountPath: /app/resources/application-helm.yml + subPath: application-helm.yml name: init-data - mountPath: /app/resources/logback.xml subPath: logback.xml diff --git a/kubernetes/cps/values.yaml b/kubernetes/cps/values.yaml index 77ebb09dd9..2312a4994d 100755 --- a/kubernetes/cps/values.yaml +++ b/kubernetes/cps/values.yaml @@ -47,7 +47,7 @@ global: virtualhost: baseurl: "simpledemo.onap.org" -image: onap/cps-and-nf-proxy:1.0.0 +image: onap/cps-and-nf-proxy:1.0.1 containerPort: &svc_port 8080 service: @@ -127,8 +127,16 @@ config: # REST API basic authentication credentials (passsword is generated if not provided) appUserName: cpsuser + spring: + profile: helm #appUserPassword: +# Any new property can be added in the env by setting in overrides in the format mentioned below +# All the added properties must be in "key: value" format insead of yaml. +# additional: +# spring.config.max-size: 200 +# spring.config.min-size: 10 + logging: level: INFO path: /tmp |