A quick start example of using Prometheus for web service monitoring using Docker and Docker Compose.
- Install Docker onto the target machine.
- Clone the GitHub repo.
- Navigate into the directory.
- Run
docker build -t test/webservice:latest .
to build the test web service. - Run
docker-compose up
to bring up the application. - Navigate to
http://localhost/
in a web browser and you should see the 'Hello' returned. - Using a tool such as Postman, do a
PUT
tohttp://localhost/orders/
with a body of{"orderId": "1234567","orderValue": "123.45"}
. - Do a
GET
tohttp://localhost/1234567
and the original data should be displayed.
The work is based on Kai Hendry's Pingprom project.