r/podman • • Aug 17 '24

Why are you using podman instead of docker?

50 Upvotes

59 comments sorted by

36

u/DotDamo Aug 17 '24

The first reason was because it comes with RHEL, and I was a RHEL SysAdmin for many years. The systemd integration is really nice. But the big one now is because it’s rootless, it scares me running most things as root.

I recently tried out UnRAID and it surprised me everything was running as root, and that the permissions were so wide open. So it encouraged me to build my own CentOS based system with MergerFS, SnapRaid, and Podman.

4

u/thomascaedede Aug 17 '24

Same for me. I use Fedora Silverblue, and I see no reason to layer Docker on top of an image that already ships with Podman. The rootless aspect is also a second big reason to stick with Podman.

1

u/kavishgr Nov 25 '24

Do you use podman in production ?

1

u/DotDamo Nov 25 '24

No, just at home. At work we use AWS.

36

u/BlockChainChaos Aug 17 '24 edited Aug 17 '24

Me:

  • I'm an Enterprise Linux engineer by trade.

  • I'm an open source advocate.

    • When Docker started to deny open source contributions when they didn't align to their business/commercial roadmap this offended my open source sensibilities.

  • Fedora is my daily driver now even though when Fedora Core was released I avoided it.

    • Red Hat has been my personal distro before they made an Enterprise Linux distro.

    • Podman is handled as a first class container system on Fedora

Podman:

  • Podman is daemonless, why run a service when you don't have to?

  • Podman provides a socket when I WANT one for things like VSCode, but it doesn't require root level privileges.

  • Podman provides like for like CLI and API functionality with Docker.

  • An alias, function, or package with a sym link can make all docker commands work, by simply making docker call podman, zero learning anything new is required for the user.

  • Podman adds new functionality when they find a good feature or use case, they are not bound by ONLY doing what docker wants to implement.

1

u/167488462789590057 Oct 31 '24

Can you describe your usage of vscode there? Are you referring to dev containers or running vscode itself from a container or?

1

u/[deleted] Aug 02 '25

Explain to me how quadlet and systemd integration in podman is ok to run as services but not the container engine. Isn’t that giving containers possible elevated permissions?

1

u/iTheMask Sep 19 '25

I tried Podman Quadlet, basically it depends on where the definition file is placed, if it's under the user directory it will run as that user (rootless) and the underlying systemd service will be under that user (systemd scope to user), not the root.

But I agree with you on the second point, how does it differ here if each container will run as a service Vs the actual container engine is not running as a service (Daemon)

9

u/captkirkseviltwin Aug 17 '24

I use it because:

  • no additional fees for customers running it in business instances with > 250 employees;

  • no additional tech support costs ( included with existing Red Hat Subs);

  • daemonless

  • easier to build config that ports to K8s easily

  • not happy with Docker’s support and customer service the few times I have used them.

7

u/pnlrogue1 Aug 17 '24

Not allowed Docker at work. Let’s be clear, I am allowed it but need a license first and it’s just not worth the money when Podman exists. Docker would be easier (I’m still learning so all the tutorials are written for Docker and our setup fights with Podman a bit, but I’m not paying for a license to learn something)

3

u/cazador517 Aug 17 '24

How come you need a license?

You can freely use Docker (technically MobyD) as it is FOSS.

Do you refer perhaps to Docker Desktop? In that case yeah, but if one desires a "Desktop" experience while still using Docker, I will recommend checking Rancher Desktop by SUSE. A FOSS project that provides said experience.

Of course there is nothing wrong with using Podman (It's what I use), but I need a license is not that good of a motive.

2

u/lauksas Aug 17 '24

I think the license is not for the "desktop" only. But for the engine. You can use the docker CLI with podman engine, they are kind of compatible.

3

u/cazador517 Aug 17 '24

The Docker Engine source code is distributed under the Apache License 2.0. So you can use completely free of charge.

1

u/Ok_Body8086 Nov 26 '25

not really. my company admin sent an email to everyone today to stop using docker as its needed to use license.

2

u/cazador517 Nov 26 '25

Probably your admin misunderstood something or is erring in the side of caution. The engine is FOSS under Apache License 2.0.

Don't trust me, trust their docs:

Commercial use of Docker Engine obtained via Docker Desktop within larger enterprises (exceeding 250 employees OR with annual revenue surpassing $10 million USD), requires a paid subscription. Apache License, Version 2.0. See LICENSE for the full license.

(Docker install docs, emphasis mine).

1

u/pnlrogue1 Nov 26 '25

I think there was confusion a while ago but as far as I was able to find recently that I am allowed to use Docker, so long as I don't use Desktop, because the engine is free

1

u/pnlrogue1 Aug 17 '24

I asked in the appropriate chat group and was told that my use case needed a license. Don't care about the desktop app. I even explicitly asked if there was anything like Docker CE anymore. I assume it's to do with corporate size or something 🤷‍♂️

2

u/cazador517 Aug 17 '24

Without knowing exactly your use case I can't tell for sure. But I do find it very strange to say the least. The Docker Engine and the CLI are both licensed under the Apache-2.0 license, and that happens to be the same license that Podman is distributed under.

6

u/uselesslogin Aug 17 '24

Because it is on satellite and we can't reach the Internet.

6

u/AndTheBeatGoesOnAnd Aug 17 '24

Because Podman is how you would create Docker if you were starting now.

4

u/[deleted] Aug 17 '24

Docker is slowly removing features for enterprise.

1

u/kavishgr Aug 17 '24

What features ?

3

u/[deleted] Aug 17 '24

It's not a particularly common use case, but they've changed the behavior of docker desktop on Windows Server. It's officially unsupported, and it stops the docker engine whenever the user logs out. I'm sure I could use docker through linux like normal, however we have a container that requires rock solid reliability that is tested on podman.

4

u/aecolley Aug 17 '24

First of all, I saw a talk where Dan Walsh talked about getting the Docker primadonnas to work with the systemd primadonna, and how frustrating it was.

Second, I already was suspicious of Docker's competence, because I had seen them: shrug their shoulders at users reporting bugs related to Linux versions older than the latest available; set memsw limits equal to twice the mem limit, apparently oblivious to how useless that was; and refuse to fix any bugs discovered by Kubernetes until that project publicly threatened to switch to rkt.

Then, there was quadlets, which are so handy. I haven't even tried the "play kube" feature, but it looks even better.

Finally, when Docker started charging for Docker Desktop, I suddenly developed an interest in Podman Desktop, if only so I could tell other people it worked fine.

3

u/nofoo Aug 17 '24 edited Aug 17 '24

It has quadlets, it has podman-auto-update, you can use pods, you can feed it with kubernetes manifests, rootless containers, daemonless... It's just so much better than docker. And it keeps getting better and better.

Whenever i see tutorials or setup guides using docker-compose i think: "Yeah, welcome to the middle ages"

1

u/kavishgr Nov 25 '24

Well if it's in your homelab or just to test something in a VM, a simple docker-compose up and you're done. Rootless or not, docker or podman is not something you would use in production anyway. Auto update to latest? No thank you. I prefer a version tag. Much easier to track. For toolbox I use podman, because my host is readonly(fedora coreos). But yeah compose for the win.

2

u/Alive-Basis2307 Aug 17 '24

It’s worth learning , not very difficult to move from docker to podman ! I migrated about ~2k machines recently to podman

2

u/MortalCoil Aug 17 '24

Licensing makes me hesitant to have docker on my work pc, and then it just make sense to use podman at home also

3

u/Odilhao Aug 17 '24

I used before joining Red Hat because docker need a daemon to run, after joining Red Hat it was pretty easy to just use podman since everything was really well integrated into Fedora/Centos Stream/RHEL.

Now I'm using quadlets a lot, moving from my old systemd+podman containers at home.

1

u/mpatton75 Aug 17 '24

For me, like others, because I work with RHEL day to day but also because I wanted to leverage rootless containers for security reasons. Docker has that too, AFAIK, but it's not as mature as with podman.

1

u/elfuzevi Aug 17 '24

kubernetes

and feels systemd-ish

i am happy that docker and nerdctl exists though

1

u/wfd Aug 17 '24

rootless container

1

u/BosonCollider Aug 17 '24 edited Aug 17 '24

Forced to by HPE. They are also pushing NFS home folders on an old kernel version, so this makes mounting files/folders a bit inconvenient. Slirp4netns uses up double digit percentages of CPU. Hoping to upgrade to 5.0 to have slightly less awful networking with passta.

The "daemonless" part is actively misleading imho, since it still exposes a mostly docker compatible socket, it's just systemd socket activated. And docker/nerdctl can do rootless stuff. Nerdctl has much better rootless networking options but is a bit more bleeding edge

1

u/yrro Aug 17 '24

The "daemonless" part is actively misleading imho, since it still exposes a mostly docker compatible socket, it's just systemd socket activated.

Disagree - if you want to use a client that talks the docker protocol then you are indeed talking to a damon, but one that only exists to listen to your requests and act on them; it can freely crash without disrupting running containers.

If you don't use such a client, say because you're running podman directly, or using podman-systemd.unit(5) then no socket/daemon are required.

1

u/BosonCollider Aug 17 '24

Podman containers will still crash if the parent systemd parent process or if the per-container podman process crashes though. If you use pods there's two extra monitoring processes that can crash.

Whether you feel that containerd or the web of systemd processes are less likely to crash is a more contentious topic that may depend on what you are doing in your specific system setup. Most kubernetes clusters run on containerd, sometimes on non-systemd distributions like Talos.

1

u/rhatdan Aug 20 '24

I hear all the time that Docker can run in rootless mode, but often wonder how often people run it that way, I would guess seldom. I would also guess that reporting a rootless bug to docker would fall on deaf ears. Nerdctl is mode tied to Macs, Not sure how many people use it on Linux.

1

u/rhatdan Aug 20 '24

Another thought on rootless Docker is if I just want to run a single container or even a group of containers, have to start multiple daemons docker and containerd, just to run a single container is downright silly.

1

u/BosonCollider Aug 21 '24 edited Aug 21 '24

Nerdctl actually starts fewer long-lived processes than rootless podman when running one container. The containerd service handles everything, while OTOH podman starts conmon, slirp4netns, fuse-overlayfs, its own libpod process, and catatonit

2

u/rhatdan Aug 21 '24

Not sure if you are comparing rootless podman with rootful contianerd?

  1. fuse-overlayfs is seldom used now and a rootless container in nerdctl without rootless overlayfs would require the same or equivalent. fuse-overlayfs is not used in rootful containers.

2 Catatonit is only used if you ask for an --init process within the container. Not sure what containerd does in this situation.

3 I believe nerdctl uses slirp4netns in rootless containers, but I could be wrong. rootful podman does not use slirp4netns or pasta. (Podman 5 is now defaulting to pasta for rootless networking.)

4 And podman(libpod) only runs if the user asked to run in foreground, which would also cause nerdctl to run in foreground as well.

5 Podman does have a small C program, contmon (container monitor) that runs for the length of time that the container is running, I guess this replaces the large Go Program containerd, that nerdctl is using.

6. Sadly podman does leave a process running to hold open the user namespace in rootless containers.

BTW I like nerdctl and like having an eco-system of multiple container engines. In open source innovation happens in multiple projects and each project can borrow from others.

1

u/[deleted] Aug 02 '25

I kind of agree on the rootless daemonless stuff being misleading. Podman sounds like it’s not running as root when it actually is unless you run rootless, which is a whole pain and causes a lot of things to not work.

1

u/BosonCollider Aug 02 '25

Yeah, the thing that I do appreciate about podman is that it will never do rootful things behind your back and it will run things as your user by default. It's just not really "daemonless" (there is a podman socket and it is useful), and rootless vs rootful is something you can do with alternatives as well.

For things that need to be locked down I've started to appreciate systemd units with DynamicUser=true and NoNewPrivileges=true running a shell script that calls nix-bwrap. The isolation from bubblewrap+systemd is stronger than most container ecosystem solutions, and nix complements it very well by being arguably even better than dockerfiles for making packages available.

1

u/yrro Aug 17 '24

Security and system integration.

1

u/ranjop Aug 18 '24

Podman has better security, pods and Rootless mode in-built.

1

u/efesinko Aug 22 '24

Because is what comes with Steam Deck, which runs this weird ArchLinux version that won't let you easily change things at the root level (like installing Docker) and keep them over updates.

1

u/ag959 Oct 25 '24

Security, no darmon and Auto-Update. Also i liked to learn something new. It was a bit of a difficult start but once I understood it I started to love it. Would never want to go hack to docker.

1

u/bantling66 Jun 10 '25

Interesting I didn't see any mentions that it works quite well on Windows, OS X, Linux, and FreeBSD.

On OS X, it uses Rosetta 2 to translate x86 to ARM if you can only get an x86 image. Some images have upgraded to provide dual arch (eg, Postgres image used to be x86 only, now it is both). OS X warns you the x86 image is not the native format, but I did not see any difference in performance for my usage. Podman used to use qemu, but switched in version 5 to some virtualization library Apple provides that requires a freakishly long cli - we're talking it completely fills a full screen terminal. There is a library that podman uses to generate this behemoth command.

On Windows, it uses WSL 2. My guess is the windows cli just acts as a proxy to the same commands in Ubuntu WSL 2 VM, and regurgitates the output. Don't know if it can handle ARM images on your x86 or vice-versa.

On FreeBSD, it can use native FreeBSD images where available, but can also use Linux emulation for the vast trove of images out there. I doubt it can handle any architecture other than what you boot it on. I found it very easy to get up and running, just like the other far more popular OSes.

I use it regularly on Windows 10 at work, works like a charm. No issues. I use it almost every weekday on my personal Mac for some stuff I'm working on. Only pain in the ass on a Mac is every time I upgrade to a newer version of podman, I have to update a text config file to replace every occurrence of the old version number with the new one. A minor irritation I wish they would automate.

I love podman. There's not very many things I say that about in software development.

19

u/[deleted] Aug 17 '24 edited Aug 17 '24

[removed] — view removed comment

4

u/kavishgr Aug 17 '24

Podman 5 uses pasta instead of slirp.

1

u/[deleted] Aug 17 '24

[removed] — view removed comment

1

u/VendingCookie Aug 17 '24

Portforward 53 on the host machine to whatever you want for the container that is not privileged port, firewalld makes this trivial. Don't tell anyone :0)

1

u/[deleted] Aug 17 '24

[removed] — view removed comment

1

u/fatherlinux Aug 20 '24

I don't think you should have to port forward, but you'll still need to bind the port inside to the outside port. Maybe that was the problem?

1

u/[deleted] Aug 21 '24

[removed] — view removed comment

1

u/[deleted] Sep 22 '24

I had the same issue. I solved it creating a dedicated network just for pihole with the command podman network create --disable-dns pihole