apiVersion: batch/v1
kind: Job
metadata:
  name: lhproducer
  namespace: logharbour
spec:
  #replicas: 1
  #selector:
   # matchLabels:
    #  app: lhproducer
  template:
    metadata:
      labels:
        app: lhproducer
    spec:
      containers:
      - name: lhproducer
        image: private-repo:5000/lhproducer:latest
        command: ["./lh-producer", "-nMessages=500", "-nGoroutines=10"]
        env:
        - name: KAFKA_BROKERS
          value: "10.109.99.64:9094"
        - name: KAFKA_TOPIC
          value: "log_topic"
      restartPolicy: Never
      nodeSelector:
        name: master
