]> git.ipfire.org Git - thirdparty/lxc.git/commitdiff
don't try to get stuff from /usr/lib/systemd on the host
authorEvgeni Golov <evgeni@debian.org>
Thu, 15 Dec 2016 18:59:13 +0000 (19:59 +0100)
committerStéphane Graber <stgraber@ubuntu.com>
Tue, 3 Jan 2017 15:51:38 +0000 (10:51 -0500)
it might not even be there…

Signed-off-by: Evgeni Golov <evgeni@debian.org>
templates/lxc-opensuse.in

index 5a917b9b5c23023d07040a2a631e7d6f5559ffdf..80ee4385255f58d89110269de534e5c7d8972361 100644 (file)
@@ -93,7 +93,7 @@ EOF
     ln -s /dev/null $rootfs/etc/systemd/system/proc-sys-fs-binfmt_misc.automount
     ln -s /dev/null $rootfs/etc/systemd/system/console-shell.service
     ln -s /dev/null $rootfs/etc/systemd/system/systemd-vconsole-setup.service
-    sed -e 's/ConditionPathExists=.*//' /usr/lib/systemd/system/getty@.service > $rootfs/etc/systemd/system/getty@.service
+    sed -e 's/ConditionPathExists=.*//' $rootfs/usr/lib/systemd/system/getty@.service > $rootfs/etc/systemd/system/getty@.service
     ln -s getty@.service $rootfs/etc/systemd/system/getty@tty1.service
     ln -s ../getty@.service $rootfs/etc/systemd/system/getty.target.wants/getty@console.service
     ln -s -f ../getty@.service $rootfs/etc/systemd/system/getty.target.wants/getty@tty1.service
@@ -103,7 +103,7 @@ EOF
 
     # copy host poweroff target as sigpwr target to make shutdown work
     # see https://wiki.archlinux.org/index.php/Linux_Containers#Container_cannot_be_shutdown_if_using_systemd
-    cp /usr/lib/systemd/system/poweroff.target $rootfs/usr/lib/systemd/system/sigpwr.target
+    cp $rootfs/usr/lib/systemd/system/poweroff.target $rootfs/usr/lib/systemd/system/sigpwr.target
 
     touch $rootfs/etc/sysconfig/kernel