# Copyright © 2017 Amdocs, Bell Canada
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#       http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

apiVersion: extensions/v1beta1
kind: Deployment
metadata:
  name: {{ include "common.fullname" . }}
  namespace: {{ include "common.namespace" . }}
  labels:
    app: {{ include "common.name" . }}
    chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}
    release: {{ .Release.Name }}
    heritage: {{ .Release.Service }}
spec:
  replicas: {{ .Values.replicaCount }}
  template:
    metadata:
      labels:
        app: {{ include "common.name" . }}
        release: {{ .Release.Name }}
    spec:
      hostname: {{ include "common.name" . }}
      containers:
      - args:
        image: "{{ include "common.repository" . }}/{{ .Values.image }}"
        imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
        name: {{ include "common.name" . }}
        ports:
        - containerPort: {{ .Values.service.externalPort }}
        - containerPort: {{ .Values.service.externalPort2 }}
        - containerPort: {{ .Values.service.externalPort3 }}
        - containerPort: {{ .Values.service.externalPort4 }}
        volumeMounts:
        - mountPath: /data
          name: aaf-cs-data
        - mountPath: /etc/localtime
          name: localtime
          readOnly: true
        # disable liveness probe when breakpoints set in debugger
        # so K8s doesn't restart unresponsive container
        {{- if eq .Values.liveness.enabled true }}
        livenessProbe:
          tcpSocket:
            port: {{ .Values.service.internalPort3 }}
          initialDelaySeconds: {{ .Values.liveness.initialDelaySeconds }}
          periodSeconds: {{ .Values.liveness.periodSeconds }}
        {{ end -}}
        readinessProbe:
          tcpSocket:
            port: {{ .Values.service.internalPort3 }}
          initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }}
          periodSeconds: {{ .Values.readiness.periodSeconds }}
        lifecycle:
          postStart:
            exec:
              command: 
              - /bin/sh
              - -c
              - >
                /bin/sleep 30;
                cd /data/;
                cqlsh -u root -p root -f keyspace.cql ;
                cqlsh -u root -p root -f init.cql ;
                cqlsh -u root -p root -f osaaf.cql ;
                cqlsh -u root -p root -f temp_identity.cql
        resources: 
{{ toYaml .Values.resources | indent 12 }}
      {{- if .Values.nodeSelector }}
      nodeSelector:
{{ toYaml .Values.nodeSelector | indent 10 }}
      {{- end -}}
      {{- if .Values.affinity }}
      affinity:
{{ toYaml .Values.affinity | indent 10 }}
      {{- end }}
      volumes:
        - name: localtime
          hostPath:
            path: /etc/localtime
        - name: aaf-cs-data
          secret:
            secretName: {{ include "common.fullname" . }}
      imagePullSecrets:
      - name: "{{ include "common.namespace" . }}-docker-registry-key"
