summaryrefslogtreecommitdiff
path: root/app-emulation/libvirt/files
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2019-08-02 19:14:55 +0100
committerV3n3RiX <venerix@redcorelinux.org>2019-08-02 19:14:55 +0100
commitb24bd25253fe093f722ab576d29fdc41d04cb1ee (patch)
tree0fcf2afd9f852c4d4c291cf8afaa2c244d598105 /app-emulation/libvirt/files
parent121ed4eec41fbf03e1998d09eede1bf449da63b9 (diff)
gentoo resync : 02.08.2019
Diffstat (limited to 'app-emulation/libvirt/files')
-rw-r--r--app-emulation/libvirt/files/README.gentoo-r22
-rw-r--r--app-emulation/libvirt/files/libvirt-5.6.0-do-not-use-sysconf.patch174
2 files changed, 175 insertions, 1 deletions
diff --git a/app-emulation/libvirt/files/README.gentoo-r2 b/app-emulation/libvirt/files/README.gentoo-r2
index 1c086c1eb5e9..6d6fb18ed3c8 100644
--- a/app-emulation/libvirt/files/README.gentoo-r2
+++ b/app-emulation/libvirt/files/README.gentoo-r2
@@ -53,6 +53,6 @@ must change the unix sock group and/or perms in /etc/libvirt/libvirtd.conf
in order to allow normal users to connect to libvirtd.
-If libvirtd is built with USE=caps, libvirt will now start qemu/kvm VMs
+If libvirt is built with USE=caps, libvirt will now start qemu/kvm VMs
with non-root privileges. Ensure any resources your VMs use are accessible
by qemu:qemu.
diff --git a/app-emulation/libvirt/files/libvirt-5.6.0-do-not-use-sysconf.patch b/app-emulation/libvirt/files/libvirt-5.6.0-do-not-use-sysconf.patch
new file mode 100644
index 000000000000..b847392cc13d
--- /dev/null
+++ b/app-emulation/libvirt/files/libvirt-5.6.0-do-not-use-sysconf.patch
@@ -0,0 +1,174 @@
+From 8b27863cd4bd4eebefe6f39b42c181d073b457ff Mon Sep 17 00:00:00 2001
+Message-Id: <8b27863cd4bd4eebefe6f39b42c181d073b457ff.1564650738.git.mprivozn@redhat.com>
+From: Michal Privoznik <mprivozn@redhat.com>
+Date: Sat, 16 Mar 2019 12:33:00 +0100
+Subject: [PATCH] gentoo: do not use sysconf
+
+Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
+---
+ src/Makefile.am | 21 ++-------------------
+ src/locking/virtlockd.service.in | 3 +--
+ src/logging/virtlogd.service.in | 3 +--
+ src/remote/libvirtd.service.in | 3 +--
+ tools/Makefile.am | 13 ++-----------
+ tools/libvirt-guests.service.in | 2 +-
+ tools/libvirt-guests.sysconf | 7 +++++++
+ 7 files changed, 15 insertions(+), 37 deletions(-)
+
+diff --git a/src/Makefile.am b/src/Makefile.am
+index 4a8cae11dc..6c93435066 100644
+--- a/src/Makefile.am
++++ b/src/Makefile.am
+@@ -750,23 +750,6 @@ endif WITH_SETUID_RPC_CLIENT
+
+ EXTRA_DIST += $(SYSCONF_FILES)
+
+-install-sysconfig:
+- $(MKDIR_P) $(DESTDIR)$(sysconfdir)/sysconfig
+- for f in $(SYSCONF_FILES:%.sysconf=%) ; \
+- do \
+- tgt=`basename $$f`; \
+- $(INSTALL_DATA) $(srcdir)/$$f.sysconf \
+- $(DESTDIR)$(sysconfdir)/sysconfig/$$tgt; \
+- done
+-
+-uninstall-sysconfig:
+- for f in $(SYSCONF_FILES:%.sysconf=%) ; \
+- do \
+- tgt=`basename $$f`; \
+- rm -f $(DESTDIR)$(sysconfdir)/sysconfig/$$tgt; \
+- done
+- rmdir $(DESTDIR)$(sysconfdir)/sysconfig || :
+-
+ LOGROTATE_FILES := $(LOGROTATE_FILES_IN:remote/%.in=%)
+
+ EXTRA_DIST += $(LOGROTATE_FILES_IN)
+@@ -825,14 +808,14 @@ SYSTEMD_UNIT_FILES = $(notdir $(SYSTEMD_UNIT_FILES_IN:%.in=%))
+ BUILT_SOURCES += $(SYSTEMD_UNIT_FILES)
+ DISTCLEANFILES += $(SYSTEMD_UNIT_FILES)
+
+-install-systemd: $(SYSTEMD_UNIT_FILES) install-sysconfig
++install-systemd: $(SYSTEMD_UNIT_FILES)
+ $(MKDIR_P) $(DESTDIR)$(SYSTEMD_UNIT_DIR)
+ for f in $(SYSTEMD_UNIT_FILES); \
+ do \
+ $(INSTALL_DATA) $$f $(DESTDIR)$(SYSTEMD_UNIT_DIR)/ ; \
+ done
+
+-uninstall-systemd: uninstall-sysconfig
++uninstall-systemd:
+ rm -f $(SYSTEMD_UNIT_FILES:%=$(DESTDIR)$(SYSTEMD_UNIT_DIR)/%)
+ rmdir $(DESTDIR)$(SYSTEMD_UNIT_DIR) || :
+
+diff --git a/src/locking/virtlockd.service.in b/src/locking/virtlockd.service.in
+index 3c9d587032..2449b201d9 100644
+--- a/src/locking/virtlockd.service.in
++++ b/src/locking/virtlockd.service.in
+@@ -7,8 +7,7 @@ Documentation=man:virtlockd(8)
+ Documentation=https://libvirt.org
+
+ [Service]
+-EnvironmentFile=-/etc/sysconfig/virtlockd
+-ExecStart=@sbindir@/virtlockd $VIRTLOCKD_ARGS
++ExecStart=@sbindir@/virtlockd
+ ExecReload=/bin/kill -USR1 $MAINPID
+ # Loosing the locks is a really bad thing that will
+ # cause the machine to be fenced (rebooted), so make
+diff --git a/src/logging/virtlogd.service.in b/src/logging/virtlogd.service.in
+index 3d9ae36150..43736191d5 100644
+--- a/src/logging/virtlogd.service.in
++++ b/src/logging/virtlogd.service.in
+@@ -7,8 +7,7 @@ Documentation=man:virtlogd(8)
+ Documentation=https://libvirt.org
+
+ [Service]
+-EnvironmentFile=-/etc/sysconfig/virtlogd
+-ExecStart=@sbindir@/virtlogd $VIRTLOGD_ARGS
++ExecStart=@sbindir@/virtlogd
+ ExecReload=/bin/kill -USR1 $MAINPID
+ # Loosing the logs is a really bad thing that will
+ # cause the machine to be fenced (rebooted), so make
+diff --git a/src/remote/libvirtd.service.in b/src/remote/libvirtd.service.in
+index 3ddf0e229b..a38f2b08fa 100644
+--- a/src/remote/libvirtd.service.in
++++ b/src/remote/libvirtd.service.in
+@@ -20,12 +20,11 @@ Documentation=https://libvirt.org
+
+ [Service]
+ Type=notify
+-EnvironmentFile=-/etc/sysconfig/libvirtd
+ # libvirtd.service is set to run on boot so that autostart of
+ # VMs can be performed. We don't want it to stick around if
+ # unused though, so we set a timeout. The socket activation
+ # then ensures it gets started again if anything needs it
+-ExecStart=@sbindir@/libvirtd --timeout 120 $LIBVIRTD_ARGS
++ExecStart=@sbindir@/libvirtd --timeout 120
+ ExecReload=/bin/kill -HUP $MAINPID
+ KillMode=process
+ Restart=on-failure
+diff --git a/tools/Makefile.am b/tools/Makefile.am
+index 2807b9f6fd..cde5dba193 100644
+--- a/tools/Makefile.am
++++ b/tools/Makefile.am
+@@ -334,15 +334,6 @@ install-data-local: install-systemd install-nss \
+ uninstall-local: uninstall-systemd uninstall-nss \
+ uninstall-bash-completion
+
+-install-sysconfig:
+- $(MKDIR_P) $(DESTDIR)$(sysconfdir)/sysconfig
+- $(INSTALL_DATA) $(srcdir)/libvirt-guests.sysconf \
+- $(DESTDIR)$(sysconfdir)/sysconfig/libvirt-guests
+-
+-uninstall-sysconfig:
+- rm -f $(DESTDIR)$(sysconfdir)/sysconfig/libvirt-guests
+- rmdir $(DESTDIR)$(sysconfdir)/sysconfig ||:
+-
+ EXTRA_DIST += libvirt-guests.sh.in
+
+ libvirt-guests.sh: libvirt-guests.sh.in $(top_builddir)/config.status
+@@ -362,12 +353,12 @@ EXTRA_DIST += libvirt-guests.service.in
+ SYSTEMD_UNIT_DIR = $(prefix)/lib/systemd/system
+
+ if LIBVIRT_INIT_SCRIPT_SYSTEMD
+-install-systemd: libvirt-guests.service install-sysconfig libvirt-guests.sh
++install-systemd: libvirt-guests.service libvirt-guests.sh
+ $(MKDIR_P) $(DESTDIR)$(SYSTEMD_UNIT_DIR)
+ $(INSTALL_DATA) libvirt-guests.service \
+ $(DESTDIR)$(SYSTEMD_UNIT_DIR)/libvirt-guests.service
+
+-uninstall-systemd: uninstall-sysconfig
++uninstall-systemd:
+ rm -f $(DESTDIR)$(SYSTEMD_UNIT_DIR)/libvirt-guests.service
+ rmdir $(DESTDIR)$(SYSTEMD_UNIT_DIR) ||:
+
+diff --git a/tools/libvirt-guests.service.in b/tools/libvirt-guests.service.in
+index 491ca62138..f0f417bffb 100644
+--- a/tools/libvirt-guests.service.in
++++ b/tools/libvirt-guests.service.in
+@@ -10,7 +10,7 @@ Documentation=man:libvirtd(8)
+ Documentation=https://libvirt.org
+
+ [Service]
+-EnvironmentFile=-/etc/sysconfig/libvirt-guests
++EnvironmentFile=-/etc/libvirt/libvirt-guests.conf
+ # Hack just call traditional service until we factor
+ # out the code
+ ExecStart=@libexecdir@/libvirt-guests.sh start
+diff --git a/tools/libvirt-guests.sysconf b/tools/libvirt-guests.sysconf
+index 669b046507..45b0b9ea46 100644
+--- a/tools/libvirt-guests.sysconf
++++ b/tools/libvirt-guests.sysconf
+@@ -1,3 +1,10 @@
++#
++# Warning: This configuration file is only sourced by the systemd
++# libvirt-guests.service unit. The coresponding openrc facility is in
++# /etc/init.d/libvirtd and /etc/conf.d/libvirtd
++#
++
++
+ # URIs to check for running guests
+ # example: URIS='default xen:///system vbox+tcp://host/system lxc:///system'
+ #URIS=default
+--
+2.21.0
+