# criando annotate deployment
# - kubectl annotate deployment portal-noticias-deployment kubernetes.io/change-cause="Subindo o portal na versão 1"
# - kubectl rollout history deployments portal-noticias-deployment

apiVersion: apps/v1
kind: Deployment
metadata:
  name: portal-noticias-deployment
spec:
  # iniciando configurações de deployment e redundâncias POD's
  replicas: 3
  selector:
    matchLabels:
      app: portal-noticias
  template:
  # iniciando configurações do POD's
    metadata:
      name: portal-noticias
      labels:
        app: portal-noticias
    spec:
      containers:
      - name: portal-noticias
        image: aluracursos/portal-noticias:1
        ports:
          - containerPort: 80
        envFrom:
          - configMapRef:
              name: portal-configmap
