Show HN: Docker minimal image size comparison for a simple JSON API in various programming languages<p>I implemented a simple JSON API in multiple programming languages. It is interesting to compare the sizes of the resulting Docker images.<p>Optimizing the images can really reduce the sizes, especially for interpreted languages: while you would expect Go and Rust to be small (and they are: 9 MB & 5 MB respectively), Python and PHP are also surprisingly good: 60 MB and 51 MB.<p>Deno, Bun, NodeJS, .Net and Ruby are between 100 and 200 MB.<p>Ruby using bitami:ruby was over 500 MB. Switching to chainguard:ruby brought it down to 124 MB.<p>I haven't optimized the Swift, Perl, Java & Tcl images which are between 200 and 300 MB.<p>Proof that they actually run and work:
<a href="https://www.regexplanet.com/status.html" rel="nofollow">https://www.regexplanet.com/status.html</a><p>Description of the API that they implement:
<a href="https://github.com/regexplanet/regexplanet-next/blob/main/CONTRIBUTING.md#backend-api">https://github.com/regexplanet/regexplanet-next/blob/main/CO...</a>