---
apiVersion: apps/v1
kind: Deployment
metadata:
  name: simplicite
  labels:
    app: simplicite
spec:
  replicas: 1
  selector:
    matchLabels:
      app: simplicite
  template:
    metadata:
      labels:
        app: simplicite
    spec:
      containers:
        - name: simplicite
          image: ${IMAGE}
          volumeMounts:
          - name: simplicite-git-volume-mount
            mountPath: /usr/local/tomcat/webapps/ROOT/WEB-INF/git
            subPath: git
          env:
          - name: DB_HOST
            value: ${DB}
          - name: DB_VENDOR
            value: ${DB}
          - name: DB_NAME
            value: simplicite
          - name: DB_USER
            value: simplicite
          - name: DB_PASSWORD
            value: simplicite
          - name: DB_SETUP
            value: "true"
          - name: DB_WAIT
            value: "100"
      restartPolicy: Always
      volumes:
      - name: simplicite-git-volume-mount
        persistentVolumeClaim:
          claimName: simplicite-git-volume-claim
