I am already fairly comfortable using docker and its tool set. Is the tide shifting towards Podman? Should I start learning how to use Podman? Thanks in advance.

38 points

I can’t help but laugh at this.

“learn how to use podman” from someone who already knows docker is their happy path.

https://docs.podman.io/en/latest/index.html#what-is-podman

Most users can simply alias Docker to Podman (alias docker=podman) without any problems

Seriously, the only two problems i’ve had are:

  1. makefile doesn’t honor the alias
  2. need to restart the VM occasionally
permalink
report
reply
9 points

I would consider myself a very beginning docker user so I’ve a long way to go but I can see, given that I am a beginner, it might make sense to pivot now to Podman.

permalink
report
parent
reply
12 points
*

It might be easier to learn some docker first. That’s what all the documentation is written for and I’ve found the “alias docker to podman and call it a day” approach to be overly optimistic.

permalink
report
parent
reply
10 points

conversely, switching now means he’ll be learning domain specific knowledge for podman, the thing he wants to work in, and not building it in docker, the thing he’s trying to move away from

permalink
report
parent
reply
6 points

I did need to install some additional stuff to get docker-compose working with podman, and I needed to make sure I ran those things as a user instead of as root to make sure that the containers created by docker-compose were running rootless. But I do have my Lemmy instance running with rootless containers using podman.

My next step is to convert it to a systemd service, but I just haven’t got there yet.

permalink
report
parent
reply
4 points

That’s the claim but buildx is extremely limited on podman.

permalink
report
parent
reply
1 point

But is it really a drop-in replacement for docker? Networking seems fundamentally different.

I tried to use a docker compose file for Wordpress as an example, with nginx-proxy-manager in another compose file. They’re linked together through an external network.

Podman works differently. You’re expected to create ‘pods’. I’m not super clear on this (just dipping my toes) but podman seems to be an alternative to k8s, not docker.

permalink
report
parent
reply
35 points

I’ve studied and used them both and prefer podman for the reasons podman promotes:

  • easy to manage containers via systemd, along with the other systems services I manage
  • better security: rootless containers.
permalink
report
reply
19 points

I use podman for almost everything. Especially since it’s working rootless. BUT I am also clearly swimming against the tide there. Everyone else in the company uses docker and I typically can’t just take their docker-compose setups 1:1 over to podman. First, because they often rely on having root and second, because they use docker specific hacks (like some internal hostname you can use to access the host from within docker). Since I am not a fan of docker-compose anyway, I don’t care that much … I would have built my own setup with docker as well.

On my server I have a lot less trouble with podman than I had with docker. I run quite a lot of services there, and the docker proxy (and sometime the daemon) always started to act up after a while, causing individual containers to no longer properly receive traffic and me no long being able to control them. With podman all of that just works. And I have systemd managing the container lifetimes instead of some blackbox.

permalink
report
reply
6 points
*

This is why our org enforces Kubernetes and Helm

Compose is simpler, and has a much easier base use case, but we’ve found it more functional as a dev tool to get the service running before making a full deployment config, rather than as an effective production solution.

permalink
report
parent
reply
2 points

Developing against k8s would kill me. I want my services and debugger running locally and don’t want to deploy shit first. In my current local setup it doesn’t matter if I spin up a service as container (because I just need it doing its thing) or if I spin it up with debugger attached in the IDE because I am developing (or debuging) it. I can fully mix-and-match at nearly every layer of the system.

Our shared dev, stage and prod systems are also fully k8s. Not with helm though. For our own stuff we have an operator with CRD, so we can easily define our business services without much boilerplate and still be consistent across the teams. The different configs are built using kustomize as part of our CD pipeline.

permalink
report
parent
reply
2 points

Yeah, compose for simple testing, then use podman convert it to k8s manifests and clean up from there for production, seems like a reasonable devx.

permalink
report
parent
reply
3 points

Why do you dislike compose?

permalink
report
parent
reply
1 point

I want full control over which containers launch when. I also typically have a different requirement in which network a container runs and I want to re-use existing databases instead of spinning up a new one for each service. I want specific container names. And so on.

In short: I want full control and customization.

permalink
report
parent
reply
1 point

You can tell which service depends on which in compose, you can create, specify and set networks and add containers to them, you can keep a central database and just add the network of it to your new services, and you can also specify a container name.

As I see it (and for my compose usage), everything you mentioned works in compose.

Besides, what is your alternative? Do you just use the docker cli? I personally found that to be way less flexible than compose.

permalink
report
parent
reply
17 points

Depending on what you’re using it for. For companies it feels like the tide is shifting toward using k8s and not caring what actually runs your containers.

permalink
report
reply
10 points

That’s been the case for years now. No sane company runs production workloads on Docker or Docker compose. There’s niche solutions like Hashicorps Nomad or Docker Swarm, but most will probably either use a Hyperscalers container offering and/or use Kubernetes.

permalink
report
parent
reply
12 points

They do, and then they write blog posts about how the complexity is killing their teams productivity.

permalink
report
parent
reply
6 points

That’s for production, in dev Docker (or podman) is very much used.

permalink
report
parent
reply
12 points

I have to admit I like the concept of rootless containers very much.

permalink
report
reply
8 points

I did too until I tried to use them. They lack several features that rooted containers have, and a lot of howtos take for granted. They’re fine for very simple containers, but expect pain an suffering.

permalink
report
parent
reply
2 points
*

You can do that with docker too, not that it’s flawless of course, networking is just awful. Same thing on Podman.

permalink
report
parent
reply

Linux

!linux@lemmy.ml

Create post

From Wikipedia, the free encyclopedia

Linux is a family of open source Unix-like operating systems based on the Linux kernel, an operating system kernel first released on September 17, 1991 by Linus Torvalds. Linux is typically packaged in a Linux distribution (or distro for short).

Distributions include the Linux kernel and supporting system software and libraries, many of which are provided by the GNU Project. Many Linux distributions use the word “Linux” in their name, but the Free Software Foundation uses the name GNU/Linux to emphasize the importance of GNU software, causing some controversy.

Rules

  • Posts must be relevant to operating systems running the Linux kernel. GNU/Linux or otherwise.
  • No misinformation
  • No NSFW content
  • No hate speech, bigotry, etc

Related Communities

Community icon by Alpár-Etele Méder, licensed under CC BY 3.0

Community stats

  • 7.5K

    Monthly active users

  • 6.6K

    Posts

  • 179K

    Comments