summaryrefslogtreecommitdiffstats
path: root/hooks
diff options
context:
space:
mode:
authorRoy Marples <roy@marples.name>2020-04-08 20:12:08 +0100
committerRoy Marples <roy@marples.name>2020-04-08 20:12:08 +0100
commitefffe67b3538a03113a4556c1cd51d2a10db6d43 (patch)
tree8ce4e5fa1e75e0af0794f443a2e55fb4cb13fc2e /hooks
parent52e4702a1c6b882907ef3f5df7178ab937c6303f (diff)
downloaddhcpcd-efffe67b3538a03113a4556c1cd51d2a10db6d43.tar.xz
linux: mount --bind real directory holding /dev/log
As systemd has the real socket in /run which doesn't help anyone but itself.
Diffstat (limited to 'hooks')
-rw-r--r--hooks/00-linux8
1 files changed, 7 insertions, 1 deletions
diff --git a/hooks/00-linux b/hooks/00-linux
index b3bf1f50..f2a09213 100644
--- a/hooks/00-linux
+++ b/hooks/00-linux
@@ -1,7 +1,13 @@
# setup chroot mounts
if [ "$reason" = CHROOT ] && [ -n "$chroot" ]; then
- for d in /dev /proc /sys /run/udev; do
+ # Special case /dev/log
+ if [ -h /dev/log ]; then
+ devlogdir=$(dirname $(readlink /dev/log))
+ else
+ devlogdir=
+ fi
+ for d in /dev /proc /sys /run/udev $devlogdir; do
[ -d "$d" ] || continue
if ! mountpoint -q "$chroot$d"; then
mkdir -p "$chroot$d"