#
# Copyright SecureKey Technologies Inc. All Rights Reserved.
#
# SPDX-License-Identifier: Apache-2.0
#

---
kind: Deployment
apiVersion: apps/v1
metadata:
  name: vault-server
spec:
  replicas: 1
  selector:
    matchLabels:
      app: vault-server
  template:
    metadata:
      labels:
        app: vault-server
    spec:
      containers:
      - name: vault-server
        envFrom:
          - configMapRef:
              name: vault-server-env
          - secretRef:
              name: vault-server-env-secret
        image: vault-server:latest
        args: ["start"]
        ports:
          - containerPort: 8081
            protocol: TCP
            name: http-port
        livenessProbe:
          httpGet:
            path: /healthcheck
            port: http-port
          initialDelaySeconds: 30
          periodSeconds: 10
          failureThreshold: 5
