kind: Pod
apiVersion: v1
metadata:
  name: securetesting-newman
  labels:
    app: securetesting-newman
spec:
  containers:
  - name: file-copy
    image: ubuntu
    command: ["/bin/bash", "-c", "tail -f /dev/null"]
    volumeMounts:
    - name: shared-data
      mountPath: /test-results
  - name: securetesting-newman
    image: erabliereapi/securetesting-newman:latest
    command: 
      - /bin/sh
      - -c
      - |
        #!/bin/sh
        newman run /testing/postman/ErabliereAPI.postman_collection.json -n 2 --reporters cli,junit --reporter-junit-export /test-results/junit-report.xml --env-var url=http://erabliere-api-service
    volumeMounts:
    - name: erabliereapi-test
      mountPath: /testing/postman
      readOnly: true
    - name: shared-data
      mountPath: /test-results
  volumes:
  - name: erabliereapi-test
    configMap:
      name: erabliereapi-postman-test
  - name: shared-data
    emptyDir: {}