Simple HTTP server that saves POSTs to Redis and returns them on GETs.
612
This is a simple HTTP (Flask) server which accepts HTTP POSTs to any endpoint, then saves the body data back to a Redis server. The data can be retrieved again by doing an HTTP GET to the same endpoint.
Use Docker Compose to bring up a Redis server as well as the HTTP server:
docker-compose up
Build and bring up the HTTP server on its own:
docker build . --tag simple-http-db
docker run -ti --rm -p 5000:5000 -e REDIS_HOST=my.redis.host simple-http-db
Or use the pre-built version from Docker Hub:
docker run -ti --rm -p 5000:5000 -e REDIS_HOST=my.redis.host flyte/simple-http-db
This project uses pipenv to install and manage virtualenvs. To install requirements and run this project:
pipenv install
pipenv run python server.py
The server will listen on port 5000 by default.
Content type
Image
Digest
Size
30.4 MB
Last updated
about 6 years ago
docker pull flyte/simple-http-db