apiVersion: apps/v1
kind: Deployment
metadata:
  name: frontend-deployment
  namespace: techchallengeapp
  labels:
    app: techchallengeapp
spec:
  replicas: 3
  selector:
    matchLabels:
      app: techchallengeapp
  template:
    metadata:
      labels:
        app: techchallengeapp
    spec:
      containers:
        - name: frontend
          image: servian/techchallengeapp:latest
          #command: ["/bin/sh"]
          args: ["serve"]
          envFrom:
          - secretRef:
              name: frontend-secret
          ports:
          - name: liveness-port
            containerPort: 3000
            hostPort: 3000
          livenessProbe:
            httpGet:
              path: /healthcheck
              port: liveness-port
            initialDelaySeconds: 15
