this post was submitted on 19 Nov 2023
21 points (88.9% liked)

Selfhosted

40132 readers
546 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:

  1. Be civil: we're here to support and learn from one another. Insults won't be tolerated. Flame wars are frowned upon.

  2. No spam posting.

  3. Posts have to be centered around self-hosting. There are other communities for discussing hardware or home computing. If it's not obvious why your post topic revolves around selfhosting, please include details to make it clear.

  4. Don't duplicate the full text of your blog or github here. Just post the link for folks to click.

  5. Submission headline should match the article title (don’t cherry-pick information from the title to fit your agenda).

  6. No trolling.

Resources:

Any issues on the community? Report it using the report flag.

Questions? DM the mods!

founded 1 year ago
MODERATORS
 

I have a Podman container with Jellyfin running in it. It runs fine without SELinux, but it always crashes whenever SELinux is enabled. This will be an instance that will only be accessible in my private network.

Should I:

  • figure out how to use SELinux with Podman
  • uninstall SELinux
  • use a different server distro (Debian, Ubuntu)

If I should figure out SELinux, please point me to some resources as I could not find anything easy enough for me through a simple Google search.

top 7 comments
sorted by: hot top controversial new old
[–] [email protected] 11 points 1 year ago (1 children)

Try mounting volumes with :z at the end.

But it is pretty easy to turn SELinux into permissive mode or disable it all together via the config file.

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

Z or z. Depends on the scenario

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

Personally I would lean towards finding out why its borking with SELinux and fixing that. It really shouldn't be too hard. As others have mentioned it may be as simple as how you are mounting volumes into your containers - or it could be changing the SELinux context type for some files.

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

Just make sure to mount your volumes with the :z or :Z flags. I have disabled SELinux on servers in the past, but never when I've just used podman containers, since "it just works" with SELinux. Literally never had any problems with containers and SELinux.

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

Write your own selinux module with audit2allow.

I'm not at work so I can't find the guides I use but this looks similar https://danwalsh.livejournal.com/24750.html

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

You can also set SELinux to permissive mode. https://docs.fedoraproject.org/en-US/quick-docs/selinux-changing-states-and-modes/#_changing_to_permissive_mode

This way it is basically disabled, but you can reenable it without any problems.