# 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: {{ include "common.release" . }}
    heritage: {{ .Release.Service }}
spec:
  replicas: {{ .Values.replicaCount }}
  template:
    metadata:
      labels:
        app: {{ include "common.name" . }}
        release: {{ include "common.release" . }}
    spec:
      initContainers:
      - command:
        - /root/job_complete.py
        args:
        - --job-name
        - {{ include "common.fullname" . }}-galera-config
        env:
        - name: NAMESPACE
          valueFrom:
            fieldRef:
              apiVersion: v1
              fieldPath: metadata.namespace
        image: "{{ .Values.global.readinessRepository }}/{{ .Values.global.readinessImage }}"
        imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
        name: {{ include "common.name" . }}-readiness
      containers:
        - name: {{ include "common.name" . }}
          image: "{{ include "common.repository" . }}/{{ .Values.image }}"
          imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
          ports:
          - containerPort: {{ .Values.service.internalPort }}
          # 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.internalPort }}
            initialDelaySeconds: {{ .Values.liveness.initialDelaySeconds }}
            periodSeconds: {{ .Values.liveness.periodSeconds }}
          {{ end -}}
          readinessProbe:
            tcpSocket:
              port: {{ .Values.service.internalPort }}
            initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }}
            periodSeconds: {{ .Values.readiness.periodSeconds }}
          env:
            - name: ASDC_CLIENT_REST_HOST
              value: sdc-be.{{ include "common.namespace" . }}
            - name: ASDC_CLIENT_REST_AUTH
              value: "{{ .Values.config.asdcclientrestauth }}"
            - name: ASDC_CLIENT_REST_PORT
              value: "{{ .Values.config.asdcclientrestport }}"
            - name: ASDC_CLIENT_REST_PROTOCOL
              value: "https"
            - name: VID_AAI_URL
              value: https://aai.{{ include "common.namespace" . }}:{{ .Values.config.vidaaiport }}
            - name: VID_ECOMP_SHARED_CONTEXT_REST_URL
              value: http://portal-app.{{ include "common.namespace" . }}:{{ .Values.config.onapport }}/ONAPPORTAL/context
            - name: VID_MSO_SERVER_URL
              value: http://so.{{ include "common.namespace" . }}:{{ .Values.config.msoport }}/onap/so/infra
            - name: VID_MSO_PASS
              value: "{{ .Values.config.vidmsopass }}"
            - name: MSO_DME2_SERVER_URL
              value: "{{ .Values.config.msodme2serverurl }}"
            - name: MSO_DME2_ENABLED
              value: {{ .Values.global.debugEnabled | default .Values.debugEnabled | quote }}
            - name: VID_ECOMP_REDIRECT_URL
              value: https://{{ .Values.config.portalhost }}:{{ .Values.config.onapport }}/ONAPPORTAL/login.htm
            - name: VID_ECOMP_REST_URL
              value: https://portal-app:{{ .Values.config.onapportrest }}/ONAPPORTAL/auxapi
            - name: VID_ROLE_ACCESS_CENTRALIZED
              value: "{{ .Values.config.roleaccesscentralized }}"
            - name: VID_CONTACT_US_LINK
              value: "{{ .Values.config.vidcontactuslink }}"
            - name: VID_KEYSTORE_PASSWORD
              value: {{ .Values.config.vidkeystorepassword | quote }}
            - name: VID_UEB_URL_LIST
              value: message-router.{{ include "common.namespace" . }}
            - name: VID_MYSQL_HOST
              value: {{ index .Values "mariadb-galera" "service" "name" }}
            - name: VID_MYSQL_PORT
              value: "{{ index .Values "mariadb-galera" "service" "internalPort" }}"
            - name: VID_MYSQL_DBNAME
              value: {{ index .Values "mariadb-galera" "config" "mysqlDatabase" }}
            - name: VID_MYSQL_USER
              value: {{ index .Values "mariadb-galera" "config" "userName" }}
            - name: VID_MYSQL_PASS
              valueFrom:
                secretKeyRef:
                  name: {{ template "common.fullname" . }}-db
                  key: db-user-password
              #valueFrom:
              #  secretKeyRef: {name: {{ include "common.fullname" . }}, key: vid-password}
            - name: VID_MYSQL_MAXCONNECTIONS
              value: "{{ .Values.config.vidmysqlmaxconnections }}"
          volumeMounts:
          - mountPath: /opt/app/vid/etc
            name: vid-certs
          - mountPath: /etc/localtime
            name: localtime
            readOnly: true
          - mountPath: /var/log/onap
            name: vid-logs
          - mountPath: /tmp/logback.xml
            name: vid-logback
            subPath: logback.xml
          resources:
{{ include "common.resources" . | indent 12 }}
        {{- if .Values.nodeSelector }}
        nodeSelector:
{{ toYaml .Values.nodeSelector | indent 10 }}
        {{- end -}}
        {{- if .Values.affinity }}
        affinity:
{{ toYaml .Values.affinity | indent 10 }}
        {{- end }}
      # side car containers
        - name: filebeat-onap
          image: "{{ .Values.global.loggingRepository }}/{{ .Values.global.loggingImage }}"
          imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
          volumeMounts:
          - mountPath: /usr/share/filebeat/filebeat.yml
            name: filebeat-conf
            subPath: filebeat.yml
          - mountPath: /var/log/onap
            name: vid-logs
          - mountPath: /usr/share/filebeat/data
            name: vid-data-filebeat
      volumes:
        - name: vid-certs
          secret:
            secretName: {{ include "common.fullname" . }}-certs
        - name: localtime
          hostPath:
            path: /etc/localtime
        - name: filebeat-conf
          configMap:
            name: {{ include "common.fullname" . }}-filebeat-configmap
        - name: vid-logs
          emptyDir: {}
        - name: vid-data-filebeat
          emptyDir: {}
        - name: vid-logback
          configMap:
            name: {{ include "common.fullname" . }}-log-configmap
      imagePullSecrets:
      - name: "{{ include "common.namespace" . }}-docker-registry-key"
