libvirt: update to 1.1.2
This commit is contained in:
committed by
Domen Kožar
parent
656184f89c
commit
22b7f00423
@@ -1,23 +1,26 @@
|
|||||||
{ stdenv, fetchurl, pkgconfig, libxml2, gnutls, devicemapper, perl, python
|
{ stdenv, fetchurl, pkgconfig, libxml2, gnutls, devicemapper, perl, python
|
||||||
, iproute, iptables, readline, lvm2, utillinux, udev, libpciaccess, gettext
|
, iproute, iptables, readline, lvm2, utillinux, udev, libpciaccess, gettext
|
||||||
, libtasn1, ebtables, libgcrypt, yajl, makeWrapper, pmutils
|
, libtasn1, ebtables, libgcrypt, yajl, makeWrapper, pmutils, libcap_ng
|
||||||
}:
|
}:
|
||||||
|
|
||||||
let version = "1.1.1"; in
|
let version = "1.1.2"; in
|
||||||
|
|
||||||
stdenv.mkDerivation {
|
stdenv.mkDerivation {
|
||||||
name = "libvirt-${version}";
|
name = "libvirt-${version}";
|
||||||
|
|
||||||
src = fetchurl {
|
src = fetchurl {
|
||||||
url = "http://libvirt.org/sources/libvirt-${version}.tar.gz";
|
url = "http://libvirt.org/sources/libvirt-${version}.tar.gz";
|
||||||
sha256 = "1hi27d5pld925g1azx8jq0wv557wpkd6xrq6lzm91cdr2lg1wvyw";
|
md5 = "1835bbfa492099bce12e2934870e5611";
|
||||||
};
|
};
|
||||||
|
|
||||||
buildInputs =
|
buildInputs =
|
||||||
[ pkgconfig libxml2 gnutls devicemapper perl python readline lvm2
|
[ pkgconfig libxml2 gnutls devicemapper perl python readline lvm2
|
||||||
utillinux udev libpciaccess gettext libtasn1 libgcrypt yajl makeWrapper
|
utillinux udev libpciaccess gettext libtasn1 libgcrypt yajl makeWrapper
|
||||||
|
libcap_ng
|
||||||
];
|
];
|
||||||
|
|
||||||
|
patches = [ ./securtyfs_userns.patch ];
|
||||||
|
|
||||||
preConfigure =
|
preConfigure =
|
||||||
''
|
''
|
||||||
PATH=${iproute}/sbin:${iptables}/sbin:${ebtables}/sbin:${lvm2}/sbin:${udev}/sbin:$PATH
|
PATH=${iproute}/sbin:${iptables}/sbin:${ebtables}/sbin:${lvm2}/sbin:${udev}/sbin:$PATH
|
||||||
|
|||||||
@@ -0,0 +1,30 @@
|
|||||||
|
--- a/src/lxc/lxc_container.c
|
||||||
|
+++ b/src/lxc/lxc_container.c
|
||||||
|
@@ -750,7 +750,7 @@ err:
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
-static int lxcContainerMountBasicFS(void)
|
||||||
|
+static int lxcContainerMountBasicFS(bool userns_enabled)
|
||||||
|
{
|
||||||
|
const struct {
|
||||||
|
const char *src;
|
||||||
|
@@ -801,6 +801,9 @@ static int lxcContainerMountBasicFS(void)
|
||||||
|
continue;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
+ if (STREQ(mnts[i].src, "securityfs") && userns_enabled)
|
||||||
|
+ continue;
|
||||||
|
+
|
||||||
|
if (virFileMakePath(mnts[i].dst) < 0) {
|
||||||
|
virReportSystemError(errno,
|
||||||
|
_("Failed to mkdir %s"),
|
||||||
|
@@ -1530,7 +1533,7 @@ static int lxcContainerSetupPivotRoot(virDomainDefPtr vmDef,
|
||||||
|
goto cleanup;
|
||||||
|
|
||||||
|
/* Mounts the core /proc, /sys, etc filesystems */
|
||||||
|
- if (lxcContainerMountBasicFS() < 0)
|
||||||
|
+ if (lxcContainerMountBasicFS(vmDef->idmap.nuidmap) < 0)
|
||||||
|
goto cleanup;
|
||||||
|
|
||||||
|
/* Mounts /proc/meminfo etc sysinfo */
|
||||||
Reference in New Issue
Block a user