Sign inSign up

mintsystem/varlog

Sponsored OSS

By mintsystem

Updated over 1 year ago

VarLog is a simple mock HTTP service written in Rust that logs all incoming HTTP requests.

Image
0

10K+

mintsystem/varlog repository overview

VarLog

Docker pulls

VarLog is a simple mock HTTP service written in Rust that logs all incoming HTTP requests.

  • 🌐 Accepts all HTTP methods (GET, POST, PUT, DELETE, etc.)
  • ✅ Returns HTTP 200 OK for every request
  • 📝 Logs request details (method, path, headers, body, timestamp)
  • 🖥️ Provides a web UI to view and download request logs
  • 🔄 Outputs request information to the console in real-time
  • 💾 Stores all requests in a text file for persistence

Requirements

Usage

Clone the repo.

git clone [email protected]:Mint-System/VarLog.git
cd VarLog

Run the rust app.

task run

This will start the service at http://127.0.0.1:8080.

Interact with VarLog

You can send any HTTP request to any path on the server:

curl http://127.0.0.1:8080/any/path

curl -X POST http://127.0.0.1:8080/api/data -d '{"key": "value"}'

curl -X PUT http://127.0.0.1:8080/resource/123 -d '{"status": "updated"}'

curl -X DELETE http://127.0.0.1:8080/resource/123

To view the received requests visit http://127.0.0.1:8080/ui in your browser.

You can also get the received requests from the api endpoint.

curl http://127.0.0.1:8080/api

Develop

Container image

Build the image.

task build

Run the container.

task start

Publish the container.

task publish

Tag summary

Content type

Image

Digest

sha256:9205368ea

Size

36.9 MB

Last updated

over 1 year ago

docker pull mintsystem/varlog

This week's pulls

Pulls:

4

Last week