Hacker News new | ask | show | jobs
by cactus2093 2025 days ago
I guess call me new fashioned, but I've never really understood how to use debian packages well. I recall vaguely looking into the dpkg and build commands many years ago, it felt kind of inscrutable and clunky and I didn't find good resources that made it easy to learn so I just gave up on it and kept using the shell script to install the thing I needed with its dependencies.

By contrast, docker build and docker run are super simple to get started with (at least at a high level, figuring out the right order of flags and options to mount volumes and expose ports can get a little cumbersome). And the docker registry is super simple to browse. It's so easy to get up and running with, and the model it promises of isolation and self-contained dependencies makes a lot of sense which I think is why it has taken off so much. Despite the fact, which I think is what you're pointing out, that there often end up being a lot of pitfalls lurking just around the corner.

4 comments

I think this too. Debian packages I'm sure are powerful but I never sat down and RTFM yet, which I think is a solid requirement. Docker is easier to understand and I picked it up pretty easily just running through a quick tutorial.

Definitely pros/cons to both depending on your situation. I can imagine debian packages being more useful in large scale multi-developer environments.

A deb file is just an ar archive of 2 tgzs, one with metadata and one with the actual files.

Now, the tools that build them are a whole different kettle of fish.

Plus some stuff is really old school, ar is an archive format that nobody has used on its own since 1996, it's a sort of transparent bundler/archiver à la tar, I think it was originally used to bundle .so file into a bigger package but still have the symbols inside visible. I don't really remember all the details, it's been a while since I looked into .deb packages.

I think the main problem is that Debian is not a commercial project and it shows sometimes. The tooling is kind of "hidden" (you have to poke around the distribution, mailing lists, etc. to figure things out) and the processes are kind of the same thing. The docs on the site are ok in some regards but they're far from complete and up-to-date.

Meanwhile the Dockerfile format is reasonably well documented and the tooling is also quite straightforward. You can see that a company made it for a while its raison d'être and wanted to make it easy to use.

I'm totally the opposite (old fashioned?), if I want to play with some library I just 'fire up' an rpm so I don't have untracked files spread around /usr/lib.

Having a multi-megabyte docker container to run some random program just seems...wasteful.

It's a mistake to assume that just because you're using docker, you now shouldn't bother understanding how (debian's) packaging works.

You're usually still installing packages and working with a debian/ubuntu/whatever distribution, except they're in a container now.

Docker is an additional abstraction layer one should understand, not a replacement for an existing one.

If you are used to dealing with debian packaging and running stuff directly on your server, using docker can feel like taking a step forward, but also two backwards. A few things are better, but a bunch are worse.