kind: Deployment
apiVersion: apps/v1
metadata:
  name: sample-backend-canary
spec:
  replicas: 1
  selector:
    matchLabels:
      app: sample
      role: backend
      env: canary
  template:
    metadata:
      name: backend
      labels:
        app: sample
        role: backend
        env: canary
    spec:
      containers:
      - name: backend
        image: gcr.io/cicd-kube-305401/sample-app
        resources:
          limits:
            memory: "500Mi"
            cpu: "100m"
        imagePullPolicy: Always
        readinessProbe:
          httpGet:
            path: /health
            port: 8080
        env:
        - name: COMPONENT
          value: backend
        - name: VERSION
          value: canary
        ports:
        - name: backend
          containerPort: 8080