This image run following command
CMD ["/thttpd", "-D", "-h", "0.0.0.0", "-p", "3000", "-d", "/home/static", "-u", "static", "-l", "-", "-M", "60"]
At this point, you can convert the image we built so far into a base image for all your static websites and push it to a registry, so that you can skip the alpine step entirely. Or you can simply use my Docker Hub build:
FROM sumarsono/thttpd:latest
COPY . .
This produces a single-layer image of 186KB + whatever the size of your static website and nothing else. If you need to configure thttpd in a different way, you can just override the CMD line:
FROM sumarsono/thttpd:latest
COPY . .
CMD ["/thttpd", "-D", "-h", "0.0.0.0", "-p", "3000", "-d", "/home/static", "-u", "static", "-l", "-", "-M", "60"]
More information: https://lipanski.com/posts/smallest-docker-image-static-website
docker pull sumarsono/thttpd:latest