kind: Job
apiVersion: batch/v1
metadata:
  name: elastic-configuration
spec:
  backoffLimit: 5
  template:
    spec:
      restartPolicy: Never
      containers:
        - name: elastic-configuration
          image: gclef/elasticsearchconfig:1.10
          imagePullPolicy: "IfNotPresent"
          env:
            - name: ES_PASSWORD
              valueFrom:
                secretKeyRef:
                  name: malware-collection-secrets
                  key: ES_PASSWORD
            - name: ES_HOST
              valueFrom:
                secretKeyRef:
                  name: malware-collection-secrets
                  key: ES_HOST
            - name: ES_USERNAME
              valueFrom:
                secretKeyRef:
                  name: malware-collection-secrets
                  key: ES_USERNAME
      imagePullSecrets:
        - name: registrycreds