Skip to content

Commit bf0c182

Browse files
author
Emilien Macchi
committed
build/base: symlink dbus only in /run/dbus
In previous patches, we symblinked all /run to /var/run but it broke some services like cloud-init: some symlinks were using relative paths in /run and because of the symlink to /var/run, cloud-init was broken (maybe and for sure other services thinkin they are in /run). [root@os-ci-test4 ~]# ls -al /run/cloud-init/ total 0 drwxr-xr-x 2 root root 60 Aug 21 06:47 . drwxr-xr-x 24 root root 720 Aug 21 06:47 .. lrwxrwxrwx 1 root root 36 Aug 21 06:47 status.json -> ../../var/lib/cloud/data/status.json [root@os-ci-test4 ~]# ls -al /var/run/cloud-init/ total 0 drwxr-xr-x 2 root root 60 Aug 21 06:47 . drwxr-xr-x 24 root root 720 Aug 21 06:47 .. lrwxrwxrwx 1 root root 36 Aug 21 06:47 status.json -> ../../var/lib/cloud/data/status.json This patch create a symlink from /var/run/dbus/system_bus_socket to /run/dbus/ because it's today the only one issue we had in the deployment of RHEL7. Signed-off-by: Emilien Macchi <emilien.macchi@enovance.com>
1 parent 70368ab commit bf0c182

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

build/base.install

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -334,10 +334,10 @@ systemd_fix() {
334334
case "$dist" in
335335
$supported_centos_dists|$supported_redhat_dists)
336336
if [ $CODENAME_MAJOR = 7 ]; then
337-
if [ -d $target/run ]; then
338-
rm -rf $target/run
337+
if [ -d $target/run/dbus ]; then
338+
rm -rf $target/run/dbus
339339
fi
340-
do_chroot $target ln -sf /var/run /
340+
do_chroot $target ln -sf /var/run/dbus/system_bus_socket /run/dbus/
341341
fi
342342
;;
343343
esac

0 commit comments

Comments
 (0)