Newman with Docker
Follow these steps to use Newman with Docker:
1. In the Docker Hub, download your copy.
2. Ensure you have Docker installed and running in your system. Docker has extensive installation guidelines for popular operating systems. Choose your operating system and follow the instructions.
To test your Docker installation, execute this command to ensure it runs without errors:
$ docker run hello-world
3. Pull the Newman docker image.
$ docker pull postman/newman;
4. Run Newman commands on the image.
$ docker run -t postman/newman run "https://www.getpostman.com/collections/0d0350a9a89d39fb6361"
The URL is a shareable public link to your collection. You can get this by clicking View more actions on a collection, choose Share collection and then click Get public link.
At this stage, you should see the Collection running in Newman and the output displayed in the terminal.
The entry point to the Docker image is Newman. So you can use all Newman command line parameters. You can also run locally stored collection files. The README of the image outlines how to mount shared data volumes.
Check out how to run Newman in Docker for Windows.
For more information on collection runs, see: