nspawn: move $NOTIFY_SOCKET into /run/host/ too
The sd_notify() socket that nspawn binds that the payload can use to talk to it was previously stored in /run/systemd/nspawn/notify, which is weird (as in the previous commit) since this makes /run/systemd something that is cooperatively maintained by systemd inside the container and nspawn outside of it. We now have a better place where container managers can put the stuff they want to pass to the payload: /run/host/, hence let's make use of that. This is not a compat breakage, since the sd_notify() protocol is based on the $NOTIFY_SOCKET env var, where we place the new socket path.
This commit is contained in:
@@ -60,7 +60,7 @@ function check_norbind {
|
||||
|
||||
function check_notification_socket {
|
||||
# https://github.com/systemd/systemd/issues/4944
|
||||
local _cmd='echo a | $(busybox which nc) -U -u -w 1 /run/systemd/nspawn/notify'
|
||||
local _cmd='echo a | $(busybox which nc) -U -u -w 1 /run/host/notify'
|
||||
# /testsuite-13.nc-container is prepared by test.sh
|
||||
systemd-nspawn $SUSE_OPTS--register=no -D /testsuite-13.nc-container /bin/sh -x -c "$_cmd"
|
||||
systemd-nspawn $SUSE_OPTS--register=no -D /testsuite-13.nc-container -U /bin/sh -x -c "$_cmd"
|
||||
|
||||
Reference in New Issue
Block a user