summary refs log tree commit diff
path: root/nixos/tests/virtualbox.nix
diff options
context:
space:
mode:
authorJoachim Fasting <joachifm@fastmail.fm>2016-10-24 12:43:42 +0200
committerJoachim Fasting <joachifm@fastmail.fm>2016-10-26 03:00:54 +0200
commitc86fe2224e09b2ebb30c98de0b17b72147d7d226 (patch)
treecb13edac0f1c6f067bd2926175f5942d71aa0ec7 /nixos/tests/virtualbox.nix
parent6dc6147d8f3257935ebfc71aa1faf6b3b305de53 (diff)
downloadnixlib-c86fe2224e09b2ebb30c98de0b17b72147d7d226.tar
nixlib-c86fe2224e09b2ebb30c98de0b17b72147d7d226.tar.gz
nixlib-c86fe2224e09b2ebb30c98de0b17b72147d7d226.tar.bz2
nixlib-c86fe2224e09b2ebb30c98de0b17b72147d7d226.tar.lz
nixlib-c86fe2224e09b2ebb30c98de0b17b72147d7d226.tar.xz
nixlib-c86fe2224e09b2ebb30c98de0b17b72147d7d226.tar.zst
nixlib-c86fe2224e09b2ebb30c98de0b17b72147d7d226.zip
virtualbox-{systemd-detect-virt,net-hostonlyif} test: fix dbus socket dir
The test complains[1][2] that

   Failed to start message bus: Failed to bind socket "/run/dbus/system_bus_socket": No such file or directory

In 639e5401ff51d4c0075b5ceffcbdbfec64c67db3, the dbus socket dir is set
to `/run/dbus`; in the test vm `/var/run/dbus` is used, but the standard
`/run -> /var/run` link is typically not created until stage 2 init, not
in the minimal init used here.  Thus, dbus fails to run within the test
environment .  Fix by changing `/var/run/dbus` to simply `/run/dbus`.

[1]: https://hydra.nixos.org/build/42534725
[2]: https://hydra.nixos.org/build/42523834
Diffstat (limited to 'nixos/tests/virtualbox.nix')
-rw-r--r--nixos/tests/virtualbox.nix4
1 files changed, 2 insertions, 2 deletions
diff --git a/nixos/tests/virtualbox.nix b/nixos/tests/virtualbox.nix
index 66f16ed8bcc5..02a8fc680280 100644
--- a/nixos/tests/virtualbox.nix
+++ b/nixos/tests/virtualbox.nix
@@ -11,10 +11,10 @@ let
       #!${pkgs.stdenv.shell} -xe
       export PATH="${lib.makeBinPath [ pkgs.coreutils pkgs.utillinux ]}"
 
-      mkdir -p /var/run/dbus
+      mkdir -p /run/dbus
       cat > /etc/passwd <<EOF
       root:x:0:0::/root:/bin/false
-      messagebus:x:1:1::/var/run/dbus:/bin/false
+      messagebus:x:1:1::/run/dbus:/bin/false
       EOF
       cat > /etc/group <<EOF
       root:x:0: