apiVersion: apps/v1
kind: Deployment
metadata: 
  name: results
  namespace: instavote
spec: 
  replicas: 4
  strategy:
    type: RollingUpdate
    rollingUpdate: 
      maxSurge: 1
      maxUnavailable: 1 
  revisionHistoryLimit: 4
  paused: false
  minReadySeconds: 20
  selector: 
    matchLabels: 
      role: results
    matchExpressions: 
      - {key: version, operator: In, values: [v1, v2, v3, latest]}
  template: 
    metadata:
      name: results
      labels:
        app: node
        role: results
        version: latest
    spec:
      containers:
        - name: app
          image: schoolofdevops/vote-result:latest
          ports:
            - containerPort: 80
              protocol: TCP

