---
apiVersion: batch/v1
kind: Job
metadata:
  generateName: mayastor-provision
  namespace: litmus
spec:
  template:
    metadata:
      name: litmus
      labels:
        app: mayastor-provision
    spec:
      serviceAccountName: litmus
      restartPolicy: Never
      containers:
      - name: ansibletest
        image: openebs/ansible-runner:ci
        imagePullPolicy: Always
        env:
          - name: ANSIBLE_STDOUT_CALLBACK
            #value: log_plays
            value: default

        command: ["/bin/bash"]
        args: ["-c", "ansible-playbook ./providers/mayastor/test.yml -i /etc/ansible/hosts -v; exit 0"]