Live data from Hacker News

Fly To Podman: a script that will help you to migrate from Docker

github.com

71–80 of 152 posts

Re: Fly To Podman: a script that will help you to migrate from Docker

#71
post #16

Has Podman become more user friendly in recent years? I gave it a go about three or four years ago now when Docker began their commercial push (which I don't have an issue with). This was for some hobby project, so I didn't spend a ton of time, but it definitely wasn't as set-and-forget as Docker was. I believe I had to set up a separate VM or something? This was on Linux as the host OS too. It's been a while, so apo…

Definitely more user friendly, and I love using Quadlets! For people using Flatpaks (Linux), check out the app 'Pods' as a lightweight alternative to Podman Desktop. It is still a young project, but is already a very useful way of managing your containers and pods.

As a side note, it is so _refreshing_ to observe the native apps popping up for Linux lately, it feels like a turning point away from the Electron-everything trend. Apps are small, starts immediately and is well integrated with the rest of the system, both functionally and visually. A few other examples of native apps; Cartero, Decibels, GitFourchette, Wike – to name a few that I'm using.

Re: Fly To Podman: a script that will help you to migrate from Docker

#72

Just want to say everyone should be using podman. Its architecture is way more sane and integrates with Linux on a far more basic level (a regular process that can be started via systemd, etc. instead of a root daemon. Run it as root to get privileged containers). They've also built an incredible ecosystem around podman itself. Red Hat has been absolutely cooking with containers recently.

[dead]

Re: Fly To Podman: a script that will help you to migrate from Docker

#74
What's the podman UX/story on Windows if anyone is using it? Say for Server 2022 (prod) and Win 11 Pro (dev).

Does one prefer using WSL2 or Hyper-V as the machine provider? From what I understand, podman provides the container engine natively so nothing additional is required. Do container runtimes like containerd only come into play when using kubernetes? Not a windows specific question, but is there a reason to pick a podman native container vs one in a k8s context. I understand podman supports k8s as well. Other info: No current containers (docker or k8s) are in play.

Thanks in advance.

Re: Fly To Podman: a script that will help you to migrate from Docker

#75

Just want to say everyone should be using podman. Its architecture is way more sane and integrates with Linux on a far more basic level (a regular process that can be started via systemd, etc. instead of a root daemon. Run it as root to get privileged containers). They've also built an incredible ecosystem around podman itself. Red Hat has been absolutely cooking with containers recently.

I agree. I have been using it as a drop in docker replacement alongside podman compose via aliases for years now and I often just forget I am not using docker. The only time it bit me recently is when some scripts were looking for containers with docker specific labels and I had to figure out why they failed only for me.

Re: Fly To Podman: a script that will help you to migrate from Docker

#76

I've not looked into podman but this reminded me that I miss rkt. Anyone with experience in rkt and podman able to give me an overview of how they currently differ? I'm not a huge fan of how docker works, so I'd love an alternative.

I went from rkt to podman. Podman is compatible with Docker, including the socket/API, but is similar to rkt in that it launches the container as a child when ran directly (versus Docker, which runs all containers and storage operations under the daemon). Podman also has integration with systemd[1] though it mostly just generates boilerplate for you, since it works a lot closer to how actual daemons work. (P.S.: You might want `--new` if you want a new container each time the unit starts.)

Podman also supports running in "rootless" mode, using kernel.unprivileged_userns_clone and subuid/subgids for the sandboxing and slirp4netns for the networking. This obviously isn't exactly the same as rootful networking, but it works well enough for 99% of the use cases.

If you are running Linux, I think using Podman instead of Docker is generally a no-brainer. I think the way they've approached rootless support is a lot better than Docker and things "just work" more often than not.

[1]: https://docs.podman.io/en/latest/markdown/podman-generate-sy...

Re: Fly To Podman: a script that will help you to migrate from Docker

#77
post #62
post #13

What if I'm using docker-compose?

Enable the Podman socket and have it alias the Docker socket. Shameless plug: Alternatively, if you are on NixOS, you can just use compose2nix. https://github.com/aksiksi/compose2nix

I actually am, but want to keep configs more distro agnostic.

Re: Fly To Podman: a script that will help you to migrate from Docker

#78
Protip: if you want to use Podman (or Podman Desktop) with Docker Compose compatibility, you'll have a better time installing podman-compose [1] and setting up your env like so:

  alias docker=podman
  
  # If you want to still use Docker Compose
  # export PODMAN_COMPOSE_PROVIDER=docker-compose
  
  # On macOS: `brew install podman-compose`
  export PODMAN_COMPOSE_PROVIDER=podman-compose
  export PODMAN_COMPOSE_WARNING_LOGS=false
Most of my initial issues transitioning to Podman were actually just Docker (and Docker Desktop) issues.

Quadlets are great and Podman has a tool called podlet [2] for converting Docker Compose files to Quadlets.

I prefer using a tool like kompose [3] to turn my Docker Compose files into Kubernetes manifests. Then I can use Podman's Kubernetes integration (with some tweaks for port forwarding [4]) to replace Docker Compose altogether!

[1] https://github.com/containers/podman-compose

[2] https://github.com/containers/podlet

[3] https://github.com/kubernetes/kompose

[4] https://kompose.io/user-guide/#komposecontrollerportexpose

Re: Fly To Podman: a script that will help you to migrate from Docker

#79
post #4

Earlier quoted context omitted.

1) Podman is available in default debian repos. https://packages.debian.org/bookworm/podman 2) `podman run --entrypoint="" --rm -it debian:stable /bin/bash` in most instances you can just alias docker to podman and carry on. It uses OCI formatted images just like docker and uses the same registry infrastructure that docker uses.

Where does it pull the Debian image from? I would think the Docker infrastructure is financed by Docker Inc as a marketing tool for their paid services? Are they ok when other software utilizes it?

On my system it asks between a few different public registries, and dockerhub/docker.io is one of the choices.

t's all public infrastructure for hosting container images, I don't think Docker-the-company minds other software interfacing with it. After all, they get to call them 'Docker images', 'Dockerfiles', and put their branding everywhere. At this point

Re: Fly To Podman: a script that will help you to migrate from Docker

#80
post #77
post #62

Earlier quoted context omitted.

Enable the Podman socket and have it alias the Docker socket. Shameless plug: Alternatively, if you are on NixOS, you can just use compose2nix. https://github.com/aksiksi/compose2nix

I actually am, but want to keep configs more distro agnostic.

Your Docker Compose file remains the source of truth, so there is no “lock-in”. That’s the beauty of config generation :)
Post reply on HN