Initial import into git
This commit is contained in:
14
docker/wait-for-dbus
Executable file
14
docker/wait-for-dbus
Executable file
@@ -0,0 +1,14 @@
|
||||
#!/bin/sh
|
||||
# dlitz 2025
|
||||
set -eu
|
||||
prog="$(basename "$0")"
|
||||
socket=/run/dbus/system_bus_socket
|
||||
for i in 1 2 3 4 5 6 7 8 9 10; do
|
||||
if test -e "$socket" && socat -u stdio unix-connect:"$socket" </dev/null >/dev/null; then
|
||||
echo >&2 "$prog: dbus socket connection successful: $socket"
|
||||
exit 0
|
||||
fi
|
||||
echo >&2 "$prog: Could not connect to dbus socket $socket. Sleeping..."
|
||||
sleep 1
|
||||
done
|
||||
echo >&2 "$prog: dbus socket connection failed: continuing anyway: $socket"
|
||||
Reference in New Issue
Block a user