]> git.ipfire.org Git - thirdparty/systemd.git/commit
nspawn: register containers with both the system-wide and the per-user machined instance 39145/head
authorLennart Poettering <lennart@poettering.net>
Wed, 27 Aug 2025 12:14:18 +0000 (14:14 +0200)
committerLennart Poettering <lennart@poettering.net>
Tue, 7 Oct 2025 10:33:52 +0000 (12:33 +0200)
commit814db2ae79054d7382e69fb36a4240fdd138e5f8
tree60bea8dc09e479e399c2e095549d0628c4fb22bb
parent4e75f4778279e476ac04ab580eb8388eed1656cf
nspawn: register containers with both the system-wide and the per-user machined instance

Let's make sure each container run by unpriv users is known by both
instances. Making it known by the host instance ensures it is resovlable
by nss-myhostname (and various other tools), but making it known by the
per-user instance means the user can fully manage it on their own.

This simplifies the code a bit too, i.e. we always allocate a scope
ourselves now, and just register it, instead of letting machined do that
under some circumstances. THere's little value in that and it simplifies
things for us quite a bit.
src/nspawn/nspawn-register.c
src/nspawn/nspawn-register.h
src/nspawn/nspawn.c