Accepting request 896242 from Virtualization:containers

OBS-URL: https://build.opensuse.org/request/show/896242
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/lxd?expand=0&rev=30
This commit is contained in:
Dominique Leuenberger 2021-06-01 08:39:17 +00:00 committed by Git OBS Bridge
commit 3e83e57cc4
7 changed files with 39 additions and 100 deletions

View File

@ -1,76 +0,0 @@
From f86eaf85c38cda988589e64b643670189d22923f Mon Sep 17 00:00:00 2001
From: Aleksa Sarai <cyphar@cyphar.com>
Date: Wed, 21 Apr 2021 10:11:21 +1000
Subject: [PATCH] vm/qemu: configure spice using -spice parameter
Since QEMU 5.2, if QEMU has its modules compiled as dynamic objects to
be dlopen(2)'d rather than statically compiled into the QEMU binary,
QEMU will not accept [spice] directives through -readconfig. This is a
known issue with QEMU but has been effectively marked as WONTFIX because
-readconfig has sort-of been soft-deprecated[1,2,3].
In the meantime, just switch to the -spice commandline since this
appears to only affect modules rather than core QEMU options.
[1]: https://bugs.launchpad.net/qemu/+bug/1910696
[2]: https://lists.gnu.org/archive/html/qemu-devel/2020-11/msg02934.html
[3]: https://bugzilla.suse.com/show_bug.cgi?id=1181549#c11
SUSE-Bugs: bsc#1181549
Signed-off-by: Aleksa Sarai <cyphar@cyphar.com>
---
lxd/instance/drivers/driver_qemu.go | 6 +++++-
lxd/instance/drivers/driver_qemu_templates.go | 6 ------
2 files changed, 5 insertions(+), 7 deletions(-)
diff --git a/lxd/instance/drivers/driver_qemu.go b/lxd/instance/drivers/driver_qemu.go
index 13211f1c651f..d14267bdbb87 100644
--- a/lxd/instance/drivers/driver_qemu.go
+++ b/lxd/instance/drivers/driver_qemu.go
@@ -1043,6 +1043,7 @@ func (d *qemu) Start(stateful bool) error {
"-no-user-config",
"-sandbox", "on,obsolete=deny,elevateprivileges=allow,spawn=deny,resourcecontrol=deny",
"-readconfig", confFile,
+ "-spice", d.spiceCmdlineConfig(),
"-pidfile", d.pidFilePath(),
"-D", d.LogFilePath(),
}
@@ -1572,6 +1573,10 @@ func (d *qemu) spicePath() string {
return filepath.Join(d.LogPath(), "qemu.spice")
}
+func (d *qemu) spiceCmdlineConfig() string {
+ return fmt.Sprintf("unix=on,disable-ticketing=on,addr=%s", d.spicePath())
+}
+
// generateConfigShare generates the config share directory that will be exported to the VM via
// a 9P share. Due to the unknown size of templates inside the images this directory is created
// inside the VM's config volume so that it can be restricted by quota.
@@ -2004,7 +2009,6 @@ func (d *qemu) generateQemuConfigFile(mountInfo *storagePools.MountInfo, busName
err := qemuBase.Execute(sb, map[string]interface{}{
"architecture": d.architectureName,
- "spicePath": d.spicePath(),
})
if err != nil {
return "", err
diff --git a/lxd/instance/drivers/driver_qemu_templates.go b/lxd/instance/drivers/driver_qemu_templates.go
index aa51f45c1426..3999c2bfbb9c 100644
--- a/lxd/instance/drivers/driver_qemu_templates.go
+++ b/lxd/instance/drivers/driver_qemu_templates.go
@@ -44,12 +44,6 @@ strict = "on"
# Console
[chardev "console"]
backend = "pty"
-
-# Graphical console
-[spice]
-unix = "on"
-addr = "{{.spicePath}}"
-disable-ticketing = "on"
`))
var qemuMemory = template.Must(template.New("qemuMemory").Parse(`
--
2.30.2

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:8efd95ad4023e0d197490deb169512977ce81e3560cfd5dd93511ae438405970
size 15675966

View File

@ -1,16 +0,0 @@
-----BEGIN PGP SIGNATURE-----
iQIzBAABCgAdFiEEYC9WdmPlk7y9FPM4xjiXTWR5LWcFAmBwqVAACgkQxjiXTWR5
LWcrUg//VqiDwy5ik/tDTEUeatPSH2tugFYSCuWqR/r9w3N+nI5QDEau2AhTU8Ux
XLl9RqLbeNyuEtzrNnUXzbd0Np+X0PsKeMpXxwG0IX/n9PU31DyZlt6tU2NgC0X6
mrGQUGmWKpKrxWheAHmR6t4EXr3hU6OiGv5bmP5B7vD/ckjEYMsNA/igPVGFtMr2
nvLrU4VQ6pXfh/1a8ViE+81aIXl3pvw4a7NnXTa+nxv3zGSNQjdbx5hHrF2pKsfW
iQja3FFa/EWOzmGFGgGvL+T2m/csmA4ju1JahGxcoO1Ikejvh3Ch0+TRQGrUWeAT
T68xvgv+k5hf+XJA3+oD/cQe2KqywmxoH0IUaS4OxV5dI2PyTmz51yQuzSfwoQjB
G079XuUaZbsvNEqr8reDl3Rg8Eh0hdbUrK3u5W7KvlZOkfIqHo06xrbruxZVs27l
YSUbjjLC+JAT0t9vGJ90xFn+VoMlokkDm2nTNq5pgf3g4nmuIwVuLN1pQRHaiz6n
gjAuYHMi1uojyO0eL+JKOIedNz1a297wXugDLsy/DV7pS+cmkq6287YahHdyh6LB
PyRQJHZBw+gksMhiXo1arUBkj+5N1iTBkKT+Sk4r6qrGe8t8aE3UzBZ+zDafd8U9
LDKMvDU5dIN5xGFuFmbPdAI710WCzp8HR+3gmSUcJFYUp+YlTlE=
=lIcZ
-----END PGP SIGNATURE-----

3
lxd-4.14.tar.gz Normal file
View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:1e1ea51aec8860faae3028820d38df66f3dbf70436bc2749117c8c21c1d92ff5
size 15761618

16
lxd-4.14.tar.gz.asc Normal file
View File

@ -0,0 +1,16 @@
-----BEGIN PGP SIGNATURE-----
iQIzBAABCgAdFiEEYC9WdmPlk7y9FPM4xjiXTWR5LWcFAmCUoJoACgkQxjiXTWR5
LWcuexAAoPkFuNy+xkJxdxNfomkBB/ldZf+90VVA+ax32+4k0SsD1MqdF+ey7xCn
iMpd7wNl4ND9qSBquBeJrKLhpmzxcKX5rRyvjUh/ul2MvHRaYf+Yac/JXHttKiGx
VC0oIF6dGzkubeuxYF9o9wzu+l5yQApwwnd1a4ZhXblTRplm5YXU5INr/ItAIow8
73g5cQNUKY8XPnAtA+lNEFBgvzK8NCLzcJ/kXAqzZaxkSVDIFEoyrwvRSnb9FyB8
HzdSFzr7CdK47ckm1d4EF0rQV+cUjaboSJvWKCrAJ+B8EiMq0mQ0EBZpd0GehQ52
6obZWtVP6mrDEkFhvY9egikHoIsX+cw6GOhiBEo9X94cktAyBTZC5FujDr8ILE0q
D5u7HtZmAyieGbYcuXYCemfD1a3RRaYTBq3jrf2LQm/71dwI3FDrEzDLMqR8wzpH
qxMSrM95n0D1JZc3RXv1aJ3ct/rXcQif2zt/WsoBXMCDBtnBTvrdAF5wqxQqAkOe
w8ictY3AMYz8h86iiXYZ+Lu1zoinTPyCs1UL8v6WE8BvpceqmrwXuoKU92f+gy+j
lFSCvQVU8wN55oG5uP0WKgggJjVFYpCjPhTnmR3GolBPHWEHX0hfVaLMig0Hul0a
R7CrXghgspiDhBcrYtgBmn1848t6aC06LhKOfvQrHMXUblpZajE=
=NPrM
-----END PGP SIGNATURE-----

View File

@ -1,3 +1,22 @@
-------------------------------------------------------------------
Mon May 31 05:11:38 UTC 2021 - Aleksa Sarai <asarai@suse.com>
- Update to LXD 4.14. The full upstream changelog is available from:
https://discuss.linuxcontainers.org/t/lxd-4-14-has-been-released/11008
bsc#1186647
+ ACL support on managed bridges
+ Cluster member certificates
+ Cluster member description
+ Cluster token based join
+ Server warnings
+ Backup and snapshot project restrictions
+ User keys in device configuration
+ More auto-generated REST-API documentation
- Remove upstreamed patches:
- boo1181549-0001-vm-qemu-configure-spice-using-spice-parameter.patch
-------------------------------------------------------------------
Wed Apr 21 00:19:11 UTC 2021 - Aleksa Sarai <asarai@suse.com>

View File

@ -26,7 +26,7 @@
%define lxd_ovmfdir %{lxd_datadir}/ovmf
Name: lxd
Version: 4.13
Version: 4.14
Release: 0
Summary: Container hypervisor based on LXC
License: Apache-2.0
@ -43,8 +43,6 @@ Source101: %{name}-config.yml
# Additional runtime configuration.
Source200: %{name}.sysctl
Source201: %{name}.dnsmasq
# Backport of <https://github.com/lxc/lxd/pull/8700>. boo#1181549
Patch1: boo1181549-0001-vm-qemu-configure-spice-using-spice-parameter.patch
BuildRequires: fdupes
BuildRequires: golang-packaging
BuildRequires: libacl-devel
@ -108,8 +106,6 @@ Bash command line completion support for %{name}.
%prep
%setup -q
# boo#1181549
%patch1 -p1
# Create fake "go mod"-like import paths. This is going to be really fun to
# maintain but it's unfortunately necessary because openSUSE doesn't have nice