diff options
author | aszlig <aszlig@redmoonstudios.org> | 2015-09-15 14:14:44 +0200 |
---|---|---|
committer | aszlig <aszlig@redmoonstudios.org> | 2015-09-16 00:19:52 +0200 |
commit | 7707c7df7ff1c84a619c35a51a19593debc2d0b3 (patch) | |
tree | 9c1b05714fbfa4e9b96d6110b310d0a1b02f373b /nixos | |
parent | 89b6831ffdf368e62005a45cff7fda3d21ca7293 (diff) | |
download | nixpkgs-7707c7df7ff1c84a619c35a51a19593debc2d0b3.tar nixpkgs-7707c7df7ff1c84a619c35a51a19593debc2d0b3.tar.gz nixpkgs-7707c7df7ff1c84a619c35a51a19593debc2d0b3.tar.bz2 nixpkgs-7707c7df7ff1c84a619c35a51a19593debc2d0b3.tar.lz nixpkgs-7707c7df7ff1c84a619c35a51a19593debc2d0b3.tar.xz nixpkgs-7707c7df7ff1c84a619c35a51a19593debc2d0b3.tar.zst nixpkgs-7707c7df7ff1c84a619c35a51a19593debc2d0b3.zip |
tests/virtualbox: Start systemwide DBus in guests.
We want to check whether DBus functionality is working, so let's make sure it is running in our mini-initrd. DBus unfortunately requires to have users properly set up and another configuration file other than in ${dbus.daemon}/etc/dbus-1/system.conf, so we do provide that as well. Signed-off-by: aszlig <aszlig@redmoonstudios.org>
Diffstat (limited to 'nixos')
-rw-r--r-- | nixos/tests/virtualbox.nix | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/nixos/tests/virtualbox.nix b/nixos/tests/virtualbox.nix index 83a8b2835dc..6b74abf1320 100644 --- a/nixos/tests/virtualbox.nix +++ b/nixos/tests/virtualbox.nix @@ -8,6 +8,19 @@ import ./make-test.nix ({ pkgs, ... }: with pkgs.lib; let #!${pkgs.stdenv.shell} -xe export PATH="${pkgs.coreutils}/bin:${pkgs.utillinux}/bin" + mkdir -p /etc/dbus-1 /var/run/dbus + cat > /etc/passwd <<EOF + root:x:0:0::/root:/bin/false + messagebus:x:1:1::/var/run/dbus:/bin/false + EOF + cat > /etc/group <<EOF + root:x:0: + messagebus:x:1: + EOF + cp -v "${pkgs.dbus.daemon}/etc/dbus-1/system.conf" \ + /etc/dbus-1/system.conf + "${pkgs.dbus.daemon}/bin/dbus-daemon" --fork --system + ${pkgs.linuxPackages.virtualboxGuestAdditions}/bin/VBoxService ${(attrs.vmScript or (const "")) pkgs} |