apiVersion: apps/v1
kind: Deployment
metadata:
  name: hs-backend
  labels:
    app: hs-backend
spec:
  selector:
    matchLabels:
      app: hs-backend
  replicas: 2
  minReadySeconds: 15
  strategy:
    type: RollingUpdate
    rollingUpdate: 
      maxUnavailable: 1
      maxSurge: 1 
  template:
    metadata:
      labels:
        app: hs-backend
    spec:
      containers:
      - image: ykpgrr/hate-speech-detection-backend
        imagePullPolicy: Always
        name: hs-backend
        env:
          - name: SA_LOGIC_API_URL
            value: "http://sa-logic"
        ports:
          - containerPort: 8080
