I make Mastodon run on them... Quadlets.

#rootless #quadlets #podman #mastodon #local #development #sysadmin #homelab

Root в контейнере — это root на хосте? Разбираю особенности прав доступов в контейнерах Docker/Podman

Если назначить файлу владельца root на хосте — будет ли это тот же самый root внутри контейнера? Если на хосте существует пользователь gtosss — можно ли переключиться на него внутри контейнера и получить доступ к файлу? Если создать пользователя gtosss внутри контейнера и выдать ему права на файл — сможет ли хост обратиться к этому файлу под таким же пользователем? Большинство разработчиков знают, что контейнеры изолируют процессы. Но мало кто задумывается о том, что происходит с правами, когда например директория с хоста монтируется внутрь контейнера через volume (bind mount). Разобрал три конкретных сценария на Ubuntu с Docker и Fedora с Podman: как UID/GID влияют на доступ к файлам, почему root в контейнере может быть root на хосте и что с этим делает user namespace. Эксперименты, cli и доступные объяснения.

https://habr.com/ru/articles/1040300/

#Docker #Podman #Linux #UID #GID #user_namespace #bind_mount #SELinux #rootless #контейнеры

Root в контейнере — это root на хосте? Разбираю особенности прав доступов в контейнерах Docker/Podman

Контейнеры, в отличие от виртуальных машин, разделяют ядро с хостом. Это порождает важный вопрос: как Unix-права соотносятся между процессами внутри контейнера, соседними контейнерами и хостовой...

Хабр

In part 2 of my macOS security internals series, I demystify System Integrity Protection (SIP), breaking down how the kernel enforces Apple-signed entitlements over POSIX root privileges, the mechanics of rootless.conf, and why the hardware always has the final veto.

Includes a small C program to audit your own CSR bitfield configuration.

Read the full deep dive here:
https://bytearchitect.io/macos-security/Apple-defences-SIP-and-APFS-(cont'd)/

#macOS #infosec #cybersecurity #ReverseEngineering #XNU #AppleSecurity #Kernel #OSInternals #Rootless

" #CopyFail has proven to be a great example to refer to when writing about #Podman implementation of #rootless #containers In this note I reproduce the exploit across distinct container configurations to try to understand the exposure of a compromised rootless container."

https://garrido.io/notes/podman-rootless-containers-copy-fail/

I wondered about #rootless containers (#Podman / #Docker and found explanations how this uses user namespaces, but I was missing explanation of interactions with other namespaces (you need root to create namespaces, to do that rootless?).

I then found https://rootless.vagmi.ca implementing rootless containers from scratch and explains it very well. The user_namespaces manpage is also good to read and fills in some missing bits: https://man.archlinux.org/man/user_namespaces.7.en

TL;DR of what I learned in followup. 1/3

Introduction

@jriou Indeed I migrated on a rainy weekend !

The main issued I got was: User Namespaces, Network and obviously DNS.
This blog help me understand the the difference with #docker behaviour by setting up some demo apps:
https://giacomo.coletto.io/blog/podman-quadlets/

To experiment the #rootless mode: I followed: https://www.redhat.com/en/blog/rootless-podman-user-namespace-modes

#podman

How to install multi-container applications with Podman quadlets

Quadlet files make it easy to manage applications that need multiple containers, without needing root privileges

Giacomo Coletto

I'm still configuring my #alpinelinux + #cosmic desktop, and I realize I didn't want to install git in the main user-land on that computer, I'm being extra paranoid - and kind of petty. So I did whatever sane person would do:

- install #podman
- configure podman to be #rootless
- install #crun because rootless is not exactly what I really want
- install #toolbx
- install #git inside that isolated container
- profit

You might have noticed that I have spend some time in my Quadlets Repo, taking care of some Grafana stuff.

Took me a bit to understand it but I’m quite happy with the result.

Check it out if you’d like to deploy your Grafana instance with a few extras in your homelab!

https://codeberg.org/Spoljarevic/Quadlets/src/branch/master/rootless/containers/systemd/Monitoring%20-%20prometheus%20and%20grafana

#git #codeberg #monitoring #grafana #prometheus #NodeExporter #podmanexporter #tailscale #tailscaleexporter #podman #quadlet #quadlets #rootless

Quadlets

Containers are an essential skill for every Sysadmin. Red Hat's Podman makes this easy and secure with rootless Containers. But a normal container or Compose needs to be started manually, Quadlets change that. Use my presents and convert them into SystemD Services with the Wiki Page I wrote.

Codeberg.org

RE: https://social.wildeboer.net/@jwildeboer/115890302649611807

Thanks for that hint, @jwildeboer! Immich is up and running - import of my families libraries will take a while though… #Immich #Podman #rootless #SelfHosting