Hacker News new | ask | show | jobs
by KronisLV 1342 days ago
For those that don't necessarily want to pay for Docker and primarily want to host/build/use container images, going for self-hosted Nexus can be a more cost effective solution, as I did for my own needs: https://blog.kronis.dev/tutorials/moving-from-gitlab-registr... (albeit in my case I migrated over from GitLab Registry and now having a proxy registry as well is just an added boon)

At this point, even not signing into Docker Hub is perfectly passable, because none of my CI servers ever hit the rate limits, since Nexus can act as a caching proxy, or I can just put my own images in it. It surprises me that this isn't the de-facto way of doing things, since currently it seems like Docker Hub has to deal with a needlessly large amount of network traffic and also countless dead/abandoned images stored in it (and thus, wasted $$$).

I also use a pretty simple setup of Gitea and Drone CI for building my images from a Git repo, which works rather nicely, but perhaps that's besides the point (though you can read more about it on my blog). Of course, I won't say that building most/all of your own container images is necessarily something that you should always do.

That said, personally, I decided to focus on Ubuntu as a common base image for my own needs and install software that I need (Node, Python, JDK, .NET, Ruby and so on) inside of it through apt, as well as install updates during build time. This lead to my own container images with common tools across the board, common shared layers (e.g. fewer layers to pull if a similar image is already on the server/locally), albeit with fewer space optimizations and some caveats, about which you can read in another article of mine: https://blog.kronis.dev/articles/using-ubuntu-as-the-base-fo...

Overall, it's been a pretty reasonable experience, though I also understand why folks whose time is 10x more valuable than mine might prefer to throw money at someone, or go for images that have a bit more vendor dark magic in them (e.g. installing JDK through apt vs doing so in alternative ways that save on space).

As for Docker Desktop, if you want something like it, Rancher Desktop aims to be a passable alternative, though with a slightly different focus: https://rancherdesktop.io/

Personally, I don't think that they'll quite succeed anytime soon, because they have a long road ahead of them, much like Podman did (and still has, for some workloads), but it's definitely a promising alternative, given what else the corporation behind it has been capable of (Rancher, RKE and K3s come to mind).

1 comments

Podman is a nice alternative for Docker I think. Only Gitlab.com doens't support Podman yet with their public runners yet. Gitlab Runner itself appear to support it though
> Podman is a nice alternative for Docker I think.

I'd say that it's good for some scenarios.

It's not an entirely complete Docker alternative, there still being various inconsistencies, especially when there are projects like Docker Compose (which has Podman Compose under development) and even Docker Swarm (for which there is no direct alternative), or when something like Nomad support for Podman is still relatively new: https://developer.hashicorp.com/nomad/plugins/drivers/podman

Even then, what functionality you expect will differ for various folks, so it's going to be an instance: "But it works on my servers (for my workload and my deployments), therefore it's stable!"

Personally, I tolerate the worse architecture of Docker, just because it's widespread, reasonably stable (CLI/API wise) and I can use the same setup for both building and running containers (and even lightweight orchestration). Others might disagree, but at the end of the day use whatever works for you.

Edit: edited the post to clear up the confusion, mistakenly compared Podman with containerd, this probably threw me off: https://www.redhat.com/sysadmin/kubernetes-workloads-podman-... and https://www.redhat.com/sysadmin/compose-kubernetes-podman (it's still not an equivalent to containerd, simply can run workloads described in Kubernetes YAML)

That said, you could probably check out Podman Desktop as well, if interested: https://podman-desktop.io/

You don't need podman-compose, docker-compose is perfectly viable with podman. They've even fixed some long standing bugs/problems lately, so docker-compose v2 can also be used with podman [1].

[1] https://podman.io/releases/2022/05/09/podman-release-v4.1.0....

That's good to hear! I think Podman is going to be one of those projects that just get better and better with every subsequent release and might displace Docker for particular workloads rather easily.
Are you confusing podman with containerd perhaps?

Podman is designed to be a developer focused drop-in replacement for docker to use on one's workstation.

It's not possible to use it as a Kubernetes container runtime, there is no CRI for it to work. You can however run Kubernetes style "pods" locally from a pod manifest without a kube-apiserver which is pretty neat.

Yep, my bad! Post has been edited, I should stop posting in the evenings.

Most of the original points stand, except that Podman can run workloads described as Kubernetes YAML (or essentially compete with Rancher Desktop thanks to Podman Desktop), but isn't a runtime for Kubernetes like containerd.

A bunch of tools are still trying to catch up with pluggable container runtimes, most notably on my end right now the VS Code "Docker" plugin[0].

In general, though, I have to agree it's a nice alternative. In fact, I think it's already a better alternative for developer workstations. Getting it installed on my Windows box was just one winget command, then I was able to start the WSL host instance and get going with containers from the command line straight away. It didn't install any heavyweight UI front end, it doesn't automagically start running a bunch of services when you boot, there's no nag screens to log in or register or update, you just type some stuff on the command line and off you go. And it makes me happy that even when you SSH in to the WSL instance there's still no daemon running, you're logged in as a normal user and don't need root. It just feels like a much cleaner and more modern approach to containerizing stuff for developers.

[0] https://github.com/microsoft/vscode-docker/issues/3263