From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:50032) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1e0voN-0007gY-EN for guix-patches@gnu.org; Sat, 07 Oct 2017 16:35:04 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1e0voM-0007mF-Ha for guix-patches@gnu.org; Sat, 07 Oct 2017 16:35:03 -0400 Received: from debbugs.gnu.org ([208.118.235.43]:46394) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1e0voM-0007le-F7 for guix-patches@gnu.org; Sat, 07 Oct 2017 16:35:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1e0voM-0002oW-6u for guix-patches@gnu.org; Sat, 07 Oct 2017 16:35:02 -0400 Subject: [bug#28718] [PATCH] gnu: qemu: Add sysconfdir to configure-flags. Resent-Message-ID: From: ludo@gnu.org (Ludovic =?UTF-8?Q?Court=C3=A8s?=) References: <87mv552bs5.fsf@gmail.com> Date: Sat, 07 Oct 2017 22:34:11 +0200 In-Reply-To: <87mv552bs5.fsf@gmail.com> (Oleg Pykhalov's message of "Fri, 06 Oct 2017 06:30:34 +0300") Message-ID: <877ew6k88s.fsf@gnu.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+kyle=kyleam.com@gnu.org Sender: "Guix-patches" To: Oleg Pykhalov Cc: 28718@debbugs.gnu.org Hi Oleg, Oleg Pykhalov skribis: > From 371ba5aee9ef1412753fdb43230f107087f9651b Mon Sep 17 00:00:00 2001 > From: Oleg Pykhalov > Date: Fri, 6 Oct 2017 06:24:58 +0300 > Subject: [PATCH] gnu: qemu: Add sysconfdir to configure-flags. > > * gnu/packages/virtualization.scm (qemu): Add sysconfdir to configure-fla= gs. > --- > gnu/packages/virtualization.scm | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/gnu/packages/virtualization.scm b/gnu/packages/virtualizatio= n.scm > index a8e54d684..21fc7b784 100644 > --- a/gnu/packages/virtualization.scm > +++ b/gnu/packages/virtualization.scm > @@ -111,6 +111,7 @@ > "--disable-debug-info" ; save build space > "--enable-virtfs" ; just to be sure > ,(string-append "--prefix=3D" out) > + ,(string-append "--sysconfdir=3D/tmp/etc") [...] > I've used this patch to run a QEMU VM with bridge interface. > > $ mkdir -p /tmp/etc/qemu > $ echo 'allow bridge0' | tee -a /tmp/etc/qemu/bridge.conf > # ip link add bridge0 type bridge > # ip link set dev enp6s0 master bridge0 > # ip link up bridge0 > # dhclient bridge0 > # qemu-system-x86_64 -net nic -net bridge,br=3Dbridge0 # =E2=80=A6 It feels wrong to me to default to /tmp/etc instead of /etc. Setting up a bridge requires root privileges anyway, so why not stick to /etc instead of /tmp/etc? Thanks, Ludo=E2=80=99.