this post was submitted on 19 Sep 2023
1 points (100.0% liked)

Self Hosted - Self-hosting your services.

11203 readers
10 users here now

A place to share alternatives to popular online services that can be self-hosted without giving up privacy or locking you into a service you don't control.

Rules

Important

Beginning of January 1st 2024 this rule WILL be enforced. Posts that are not tagged will be warned and if not fixed within 24h then removed!

Cross-posting

If you see a rule-breaker please DM the mods!

founded 3 years ago
MODERATORS
 

Until yesterday, I didn’t even know you could use the docker images and the same docker-compose configs with Podman.

The UI you are looking at is Cockpit, which can be installed on almost any Linux Server. I have used it before but I am amazed by its integration with Podman.

Seriously, consider trying this, once.

Here's another screenshot of Cockpit:

top 9 comments
sorted by: hot top controversial new old
[–] [email protected] 1 points 1 year ago

I originally excited by Podman, but ultimately migrated away from it. Friendship ended with Ubuntu and Docker -> CentOS and Podman -> Proxmox + Debian LXC (which has its own irritations but anyway). Off the top of my head:

  • Can't attach a containers to multiple networks. Most of my Docker Compose stacks have an Nginx reverse proxy and a network for each service.
  • But you can use pods. However since they share the same network interface if you have multiple legacy services that both insist on, say, port 80 they can't be in the same pod. They also don't isolate services, nor can you assert a specific pod is the one listening on a forwarded port.
  • Pods also have DNS issues with Nginx. It kept crashing since it couldn't resolve the hostnames of the other containers in the pod, even if they were already running. If you launch a shell inside an Nginx container the other container hostnames resolve fine. I suspect the problem is the container is launched before its behind-the-scenes DNS infrastructure is ready.
  • Podman lets you use secrets on normal containers (yay) but if the secret changes you have to recreate the container. Amazing synergy with rotating TLS certificates.
  • Endless issues with SELinux and bind mounts. My Nginx container kept crashing because SELinux didn't like the TLS certificate bind mount. This is where I reflected on the endless parade of random issues that I had no interest in solving and finally threw in the towel.

I brought all this up in another community and was told the problem was [paraphrased] "people keep trying to use Podman like they use Docker" - whatever that means. I do like a number of design choices in it, like including the command used to create containers in the metadata, and how it's easy to integrate into SystemD for things like scheduled updates.

Cockpit is pretty slick though, need to install it on my bare metal Debian host.

[–] [email protected] 1 points 11 months ago

Is it possible to connect docker / podman directly to the router? I'm operating an L2 bridge https://developers.redhat.com/articles/2022/04/06/introduction-linux-bridging-commands-and-features systemd-nspawn containers can connect to my router directly, but how to do it with docker / podman?

[–] [email protected] 1 points 1 year ago* (last edited 1 year ago) (1 children)

Judging by the screenshots, this looks very similar to Portainer. Are they basically the same tool set for different container architectures? Looks pretty interesting.

[–] [email protected] 1 points 1 year ago

Podman replaces the underlying container engine (the docker component). Portainer is a webUI that sits on top of Docker and provides you with tools to manage it. The Podman plugin for Cockpit just happens to do the same thing.

You can actually use Portainer with Podman if you want to. It's a little fiddly to set up, but it works.

The main advantage of Podman is that it's rootless by default, whereas rootless Docker is still a somewhat tricky beast to set up.

[–] [email protected] 1 points 1 year ago

Welcome on board :)

I documented a bit how to run Lemmy via Podman here: https://f-hub.org/Solarpunk/lemmy-podman

[–] [email protected] 0 points 1 year ago (1 children)

I started with podman and wanted to like it. Ultimately moved to docker because of docker compose

[–] [email protected] 1 points 1 year ago (1 children)

Compose works with podman too, you just need podman system service & to set the DOCKER_HOST env var to it's socket.

[–] [email protected] 1 points 1 year ago

So that's why my containers aren't restarting automatically on boot. Thanks!

[–] [email protected] 0 points 1 year ago

Thanks for sharing! I think I'll implement the alias in the near future once I get more comfortable w/ Docker