Redbean is just 155Kb without the need for alpine or any other dependency. You just copy the Redbean binary and your static assets, no complicated build steps and hundred MB download necessary. Check it out: https://github.com/kissgyorgy/redbean-docker
A tiny Docker image to serve static websites
11–20 of 156 posts
Re: A tiny Docker image to serve static websites
#12I love stuff like this. People will remark about how this is a waste of time, others will say it is absolutely necessary, even more will laud it just for the fun of doing it. I'm in the middle camp. I wish software/systems engineers would spend more time optomising for size and performance.
The difference between a systems engineer and a software engineer is that to a systems engineer a half functioning 5MB docker image is okay but to a software engineer a fully functional 5GB Node image is fine.
Re: A tiny Docker image to serve static websites
#13But why would you prefer Docker like this over, for example, running thttpd directly? Saves you a lot of Ram an indirection?
Benefits: can cleanly and delete 100% of what was installed. If you use something on root can always infect, save cache, logs…
I don’t want to impact anything else running on my server. I don’t want anything to depend on that either silently.
Docker is the best thing. I just can’t understand how people still can’t get the benefits yet.
Is Amazing to start a project you had 3 years ago and just works and you can deploy without reading any docs. Just spin a docker container. Eat, safe and just works.
Re: A tiny Docker image to serve static websites
#14I love stuff like this. People will remark about how this is a waste of time, others will say it is absolutely necessary, even more will laud it just for the fun of doing it. I'm in the middle camp. I wish software/systems engineers would spend more time optomising for size and performance.
Wouldn't removing Docker entirely be a good optimization?
Re: A tiny Docker image to serve static websites
#15Redbean is just 155Kb without the need for alpine or any other dependency. You just copy the Redbean binary and your static assets, no complicated build steps and hundred MB download necessary. Check it out: https://github.com/kissgyorgy/redbean-docker
Re: A tiny Docker image to serve static websites
#16Earlier quoted context omitted.
Wouldn't removing Docker entirely be a good optimization?
In terms of CPU cycles and disk space, maybe. In terms of engineer cycles, absolutely not. Which costs more?
Or a constantly-updating behemoth, running as root, installing packages from yet another unauditable repository chain?
Re: A tiny Docker image to serve static websites
#17Redbean is just 155Kb without the need for alpine or any other dependency. You just copy the Redbean binary and your static assets, no complicated build steps and hundred MB download necessary. Check it out: https://github.com/kissgyorgy/redbean-docker
And it does https/tls, where thttpd does not.
Either way though, it's a great article I'm glad the author took to write. His docker practices are wonderful, wish more engineers would use them.
Re: A tiny Docker image to serve static websites
#18Re: A tiny Docker image to serve static websites
#19Earlier quoted context omitted.
Wouldn't removing Docker entirely be a good optimization?
Docker adds other value to the lifecycle of your deployment. An "optimization" where you're removing value is just a compromise. Otherwise we'd all run our static sites on UEFI.
docker has dead whale on the beach vibes. what value does it offer to those of us who have moved on from the mess linux is becoming?
Re: A tiny Docker image to serve static websites
#20For static websites, hosting them directly on S3 with cloudfront, or on cloudflare might be a better option?