apiVersion: apps/v1
kind: Deployment
metadata:
  name: nsq-traefik-consumer
  labels:
    team: platform
  namespace: dev
spec:
  replicas: 3
  selector:
    matchLabels:
      app: nsq-traefik-consumer
  template:
    metadata:
      labels:
        app: nsq-traefik-consumer
        team: platform
    spec:
      containers:
      - name: nsq-traefik-consumer
      #TODO proper versioning!!!!!!
        image: artifactory.wikia-inc.com/platform/nsq-traefik-consumer:v1.0.4
        args: ["--config", "/etc/nsq-traefik-consumer/config.yaml", "run"]
        volumeMounts:
        - name: config-volume
          mountPath: /etc/nsq-traefik-consumer
        resources:
          limits:
            memory: 300Mi
          requests:
            cpu: 500m
            memory: 300Mi
        env:
        - name: HOST
          valueFrom:
            fieldRef:
              fieldPath: spec.nodeName
        - name: KUBERNETES_POD
          valueFrom:
            fieldRef:
              fieldPath: metadata.name
      volumes:
        - name: config-volume
          configMap:
            name: nsq-traefik-consumer
