X-Git-Url: https://gerrit.onap.org/r/gitweb?a=blobdiff_plain;f=kubernetes%2Fportal%2Fcomponents%2Fportal-cassandra%2Ftemplates%2Fdeployment.yaml;h=e0bf941f54555044fae5454eaf7c6878d46c6888;hb=a7ac7f022a8d2553d637ad8bf5fe3f12b65aa76e;hp=84a78ab97785dd2133591fe3d63408f466c4ac93;hpb=581f2b17fd0b247eeeb4e3770b212c7e6cd631fb;p=oom.git diff --git a/kubernetes/portal/components/portal-cassandra/templates/deployment.yaml b/kubernetes/portal/components/portal-cassandra/templates/deployment.yaml index 84a78ab977..e0bf941f54 100644 --- a/kubernetes/portal/components/portal-cassandra/templates/deployment.yaml +++ b/kubernetes/portal/components/portal-cassandra/templates/deployment.yaml @@ -1,7 +1,7 @@ {{/* # Copyright (c) 2017 Amdocs, Bell Canada # Modifications Copyright (c) 2018 AT&T -# Modifications Copyright (c) 2020 Nokia +# Modifications Copyright (c) 2020 Nokia, Orange # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -62,6 +62,7 @@ spec: nodetool status initialDelaySeconds: {{ .Values.liveness.initialDelaySeconds }} periodSeconds: {{ .Values.liveness.periodSeconds }} + timeoutSeconds: {{ .Values.liveness.timeoutSeconds }} successThreshold: {{ .Values.liveness.successThreshold }} failureThreshold: {{ .Values.liveness.failureThreshold }} {{ end }} @@ -74,6 +75,7 @@ spec: nodetool status | grep -E "^UN\\s+${POD_IP}" initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }} periodSeconds: {{ .Values.readiness.periodSeconds }} + timeoutSeconds: {{ .Values.readiness.timeoutSeconds }} successThreshold: {{ .Values.readiness.successThreshold }} failureThreshold: {{ .Values.readiness.failureThreshold }} lifecycle: @@ -108,6 +110,16 @@ spec: value: rack1 - name: CASSANDRA_ENABLE_RPC value: "true" + {{- $flavor := include "common.flavor" . }} + {{- $heap := pluck $flavor .Values.heap | first }} + {{- if (hasKey $heap "max") }} + - name: MAX_HEAP_SIZE + value: {{ $heap.max }} + {{- end }} + {{- if (hasKey $heap "new") }} + - name: HEAP_NEWSIZE + value: {{ $heap.new }} + {{- end }} volumeMounts: - mountPath: /etc/localtime name: localtime @@ -117,8 +129,7 @@ spec: subPath: portal.cql - name: {{ include "common.fullname" . }}-data mountPath: /var/lib/cassandra/data - resources: -{{ include "common.resources" . | indent 12 }} + resources: {{ include "common.resources" . | nindent 10 }} {{- if .Values.nodeSelector }} nodeSelector: {{ toYaml .Values.nodeSelector | indent 10 }} @@ -127,6 +138,7 @@ spec: affinity: {{ toYaml .Values.affinity | indent 10 }} {{- end }} + serviceAccountName: {{ include "common.fullname" (dict "suffix" "read" "dot" . )}} volumes: - name: cassandra-docker-entrypoint-initdb configMap: