X-Git-Url: https://gerrit.onap.org/r/gitweb?a=blobdiff_plain;f=kubernetes%2Fcommon%2Fpostgres%2Ftemplates%2F_deployment.tpl;h=e0a0ffdef07b365adbab3c4bd6b741bbf0a93ef3;hb=a7ac7f022a8d2553d637ad8bf5fe3f12b65aa76e;hp=d93d401ebcd6e80e2192f138643f32f3f17bf5fc;hpb=ffbb82ee45ba888a4e4a543c789fb10acf01f3bb;p=oom.git diff --git a/kubernetes/common/postgres/templates/_deployment.tpl b/kubernetes/common/postgres/templates/_deployment.tpl index d93d401ebc..e0a0ffdef0 100644 --- a/kubernetes/common/postgres/templates/_deployment.tpl +++ b/kubernetes/common/postgres/templates/_deployment.tpl @@ -1,6 +1,7 @@ {{/* # Copyright © 2018 Amdocs, AT&T, Bell Canada # Copyright © 2020 Samsung Electronics +# Copyright © 2021 Orange # Modifications Copyright (C) 2021 Bell Canada. # # # # Licensed under the Apache License, Version 2.0 (the "License"); @@ -32,6 +33,8 @@ metadata: name: "{{ index $dot.Values "container" "name" $pgMode }}" spec: replicas: 1 + strategy: + type: Recreate selector: matchLabels: app: {{ include "common.name" $dot }}-{{ $pgMode }} @@ -126,9 +129,9 @@ spec: - name: PG_MODE value: {{ $pgMode }} - name: PG_PRIMARY_HOST - value: "{{ $dot.Values.container.name.primary }}" + value: "{{ $dot.Values.service.name2 }}" - name: PG_REPLICA_HOST - value: "{{ $dot.Values.container.name.replica }}" + value: "{{ $dot.Values.service.name3 }}" - name: PG_PRIMARY_PORT value: "{{ $dot.Values.service.internalPort }}" - name: PG_PRIMARY_PASSWORD @@ -155,7 +158,7 @@ spec: - mountPath: /backup name: {{ include "common.fullname" $dot }}-backup readOnly: true - resources: {{ include "common.resources" $dot | nindent 12 }} + resources: {{ include "common.resources" $dot | nindent 10 }} {{- if $dot.Values.nodeSelector }} nodeSelector: {{ toYaml $dot.Values.nodeSelector | indent 10 }}