As part of RegexPlanet, I have implemented the same basic functionality (a straightforward JSON API) with multiple technologies. I originally did them where-ever was easiest, but have been migrating them all to run in Docker, and it is interesting to compare the size of the Docker images.
| Technology | Image Size | Notes |
|---|---|---|
| Bun | 113 MB | bun's own distroless image |
| Deno | 111 MB | distroless/cc with a static binary |
| Go | 9 MB | scratch |
| Java | 212 MB | distroless/java21-debian12 (updated 2024-04-03) |
| .Net | 178 MB | chiseled-extra |
| Node.js | 152 MB | distroless/nodejs22-debian12 |
| Perl | 233 MB | debian-slim + Apache (it runs via CGI) |
| PHP | 51 MB | chainguard/php (running the built-in PHP webserver which isn't recommended) |
| Python | 60 MB | distroless/python3-debian12 |
| Ruby | 124 MB | chainguard/ruby |
| Rust | 5 MB | scratch |
| Swift | 271 MB | ubuntu-noble (standard Vapor Dockerfile) |
| tcl | 211 MB | debian-slim + Apache (it runs via CGI) |
Images were all built with Docker v24.0.7 for amd64.