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

          - name: OPERATOR_NAMESPACE
            value: openebs
 
          - name: APP_NAMESPACE
            value: app-percona-ns

          - name: APP_LABEL
            value: 'name=percona'

          - name: DB_USERNAME
            value: root

          - name: DB_PASSWORD
            value: k8sDem0

        command: ["/bin/bash"]
        args: ["-c", "ansible-playbook ./apps/percona/functional/snapshot/test.yml -i /etc/ansible/hosts -vv; exit 0"]
 
