---
apiVersion: apps/v1
kind: Deployment
metadata:
  namespace: emmental-platform
  name: back
spec:
  replicas: 1
  selector:
    matchLabels:
      app: back
      tier: backend
      track: stable
  template:
    metadata:
      labels:
        app: back
        tier: backend
        track: stable
    spec:
      containers:
        - name: back
          image: back
          imagePullPolicy: Never
          ports:
            - containerPort: 5000
          volumeMounts:
            - name: config-volume
              mountPath: /etc/config
      volumes:
        - name: config-volume
          configMap:
              name: configmap-back
      serviceAccountName: api-emmental
---
apiVersion: v1
kind: Service
metadata:
  namespace: emmental-platform
  name: back
spec:
  selector:
    app: back
    tier: backend
  ports:
    - protocol: TCP
      port: 5000
      targetPort: 5000
