It is a lightweight HTTP server and is intended for use during development and operation checks. It has the following features
source : https://github.com/morststs/zeptohttpd
$ docker run --rm -d -p 80:80 --name zeptohttpd morststs/zeptohttpd
$ curl http://localhost:
<!DOCTYPE html>
<html lang="ja">
<head>
<title>index page</title>
<meta charset="utf-8">
</head>
<body>
Hello World
</body>
</html>
Prepare static content in the public directory on your host.
$ docker run --rm -d -p 80:80 -v ./public:/public --name zeptohttpd morststs/zeptohttpd
$ cat -n config.json
1 {
2 "ContentTypes": {
3 "/api/": "application/json"
4 }
5 }
$ cat -n public/api/getData
1 {"key":"value"}
$ docker run --rm -d -p 80:80 -v ./public:/public -v ./config.json:/config.json --name zeptohttpd morststs/zeptohttpd
$ curl -D - -X POST http://localhost:/api/getData
HTTP/1.1 200 OK
Accept-Ranges: bytes
Content-Length: 16
Content-Type: application/json
Last-Modified: Sat, 24 Aug 2024 09:13:05 GMT
Date: Sun, 25 Aug 2024 02:39:20 GMT
{"key":"value"}
$ curl -D - -X GET 'http://localhost:/api/getData?val1=1&val2=2'
HTTP/1.1 200 OK
Accept-Ranges: bytes
Content-Length: 16
Content-Type: application/json
Last-Modified: Sat, 24 Aug 2024 09:13:05 GMT
Date: Sun, 25 Aug 2024 01:01:15 GMT
{"key":"value"}
Content type
Image
Digest
sha256:f9d60e44d…
Size
2.5 MB
Last updated
2 months ago
docker pull morststs/zeptohttpd