From 7e157ec941d9f6ad2d9708a4ea7fcff4183294a5f7b6304a39c8b158f9bfc31f Mon Sep 17 00:00:00 2001 From: Olaf Hering Date: Mon, 7 Sep 2015 18:30:32 +0000 Subject: [PATCH 1/3] Accepting request 329577 from home:cbosdonnat:branches:Virtualization - Add opensuse images source for virt-builder. fate#318952. OBS-URL: https://build.opensuse.org/request/show/329577 OBS-URL: https://build.opensuse.org/package/show/Virtualization/libguestfs?expand=0&rev=343 --- 0000-hotfix.patch | 111 +++++++++++++++++++++++++++++++++++++++++---- libguestfs.changes | 6 +++ libguestfs.spec | 2 +- 3 files changed, 109 insertions(+), 10 deletions(-) diff --git a/0000-hotfix.patch b/0000-hotfix.patch index bd715a5..36bd1b5 100644 --- a/0000-hotfix.patch +++ b/0000-hotfix.patch @@ -9,18 +9,17 @@ Signed-off-by: Olaf Hering 1 file changed, 1 insertion(+) create mode 100644 pkg-hotfix.txt -diff --git a/pkg-hotfix.txt b/pkg-hotfix.txt -new file mode 100644 -index 0000000..8b13789 +Index: libguestfs-1.26.10/pkg-hotfix.txt +=================================================================== --- /dev/null -+++ b/pkg-hotfix.txt ++++ libguestfs-1.26.10/pkg-hotfix.txt @@ -0,0 +1 @@ + -diff --git a/daemon/btrfs.c b/daemon/btrfs.c -index 7a4d43d..ceea593 100644 ---- a/daemon/btrfs.c -+++ b/daemon/btrfs.c -@@ -356,6 +356,7 @@ do_btrfs_subvolume_list (const mountable_t *fs) +Index: libguestfs-1.26.10/daemon/btrfs.c +=================================================================== +--- libguestfs-1.26.10.orig/daemon/btrfs.c ++++ libguestfs-1.26.10/daemon/btrfs.c +@@ -356,6 +356,7 @@ do_btrfs_subvolume_list (const mountable ADD_ARG (argv, i, str_btrfs); ADD_ARG (argv, i, "subvolume"); ADD_ARG (argv, i, "list"); @@ -47,3 +46,97 @@ Index: libguestfs-1.26.10/customize/customize_run.ml | "unknown" -> eprintf (f_"%s: --install is not supported for this guest operating system\n") prog; +Index: libguestfs-1.26.10/builder/downloader.ml +=================================================================== +--- libguestfs-1.26.10.orig/builder/downloader.ml ++++ libguestfs-1.26.10/builder/downloader.ml +@@ -97,7 +97,7 @@ and download_to ~prog t ?(progress_bar = + ) + | _ -> (* Any other protocol. *) + (* Get the status code first to ensure the file exists. *) +- let cmd = sprintf "%s%s -g -o /dev/null -I -w '%%{http_code}' %s" ++ let cmd = sprintf "%s%s -L -g -o /dev/null -I -w '%%{http_code}' %s" + t.curl + (if t.verbose then "" else " -s -S") + (quote uri) in +@@ -122,7 +122,7 @@ and download_to ~prog t ?(progress_bar = + ); + + (* Now download the file. *) +- let cmd = sprintf "%s%s -g -o %s %s" ++ let cmd = sprintf "%s%s -L -g -o %s %s" + t.curl + (if t.verbose then "" else if progress_bar then " -#" else " -s -S") + (quote filename_new) (quote uri) in +Index: libguestfs-1.26.10/builder/Makefile.am +=================================================================== +--- libguestfs-1.26.10.orig/builder/Makefile.am ++++ libguestfs-1.26.10/builder/Makefile.am +@@ -261,7 +261,7 @@ DISTCLEANFILES = .depend + # virt-builder's default repository + + repoconfdir = $(sysconfdir)/xdg/virt-builder/repos.d +-repoconf_DATA = libguestfs.conf libguestfs.gpg ++repoconf_DATA = libguestfs.conf libguestfs.gpg opensuse.conf opensuse.gpg + + install-exec-hook: + $(LN_S) xdg/virt-builder $(DESTDIR)$(sysconfdir)/virt-builder +Index: libguestfs-1.26.10/builder/Makefile.in +=================================================================== +--- libguestfs-1.26.10.orig/builder/Makefile.in ++++ libguestfs-1.26.10/builder/Makefile.in +@@ -1649,7 +1649,7 @@ DISTCLEANFILES = .depend + + # virt-builder's default repository + repoconfdir = $(sysconfdir)/xdg/virt-builder/repos.d +-repoconf_DATA = libguestfs.conf libguestfs.gpg ++repoconf_DATA = libguestfs.conf libguestfs.gpg opensuse.conf opensuse.gpg + virt_index_validate_SOURCES = \ + index-parse.y \ + index-scan.l \ +Index: libguestfs-1.26.10/builder/opensuse.conf.in +=================================================================== +--- /dev/null ++++ libguestfs-1.26.10/builder/opensuse.conf.in +@@ -0,0 +1,3 @@ ++[opensuse.org] ++uri=http://download.opensuse.org/repositories/Virtualization:/virt-builder-images/images/index ++gpgkey=file://@SYSCONFDIR@/xdg/virt-builder/repos.d/opensuse.gpg +Index: libguestfs-1.26.10/builder/opensuse.gpg +=================================================================== +--- /dev/null ++++ libguestfs-1.26.10/builder/opensuse.gpg +@@ -0,0 +1,21 @@ ++-----BEGIN PGP PUBLIC KEY BLOCK----- ++Version: GnuPG v1.4.5 (GNU/Linux) ++ ++mQENBFImAl0BCACkjaXGvVLHBGTVXVP0khtpUVHqFvCRtaIIMHaX/5oTr3nyehDQ ++Ex9VLsSRcNa0QxtnCHFRQzjWWqe+i6pBginnSjucgmjnIKyJsF4l6R+rwAiinHQX ++C4s6Lqg/wH9xDPRBrMYFqlc/7MVf0Glhk1+lAxgQjolMt+5AbbrWlBbwc/i+++zl ++ES3MaeH8aiwup/ogjhmk0SbCQQ/ib21p3XWBwx2oz/KM6Voq9tKDvMczjzNRY3ZT ++6Di3FsUSKI7kgljiNiuN+675YwqEqxWEJgdE5a7Zb67giH1Ik08b5wQiF5jSAICD ++DxW7/ibWBvZJnqhqQT2xJpLC5VaJqwkN8o83ABEBAAG0PlZpcnR1YWxpemF0aW9u ++IE9CUyBQcm9qZWN0IDxWaXJ0dWFsaXphdGlvbkBidWlsZC5vcGVuc3VzZS5vcmc+ ++iQE7BBMBAgAmBQJSJgJdAhsDBQkEHrAABgsJCAcDAgQVAggDBBYCAwECHgECF4AA ++CgkQoZP7tXIXT8ITnwf3SVUUoVjVLFCjhIxdet8BL011cJDwr9TwKEQfq4Ybsq5L ++5Y1/Zk86rTzrVOZrODLwNRIC3fMuegZV5f85KMggXu37Di+UvX+dQW9v1hte+hAT +++gsqb60kOnE/Yacgkb6D3xIzRudAB2q/xfvHl/hgfn416yGI8NvntT7n4Hk9wT28 ++9JSFkun0uaessg77aXlAdsqHwdugm9hELeva89OoYoiZ4d9r4ScTMSj0UkNgnh7g ++CyIScZHYqiiOeosUtAX9u1PyUFfFsg9s5snfud7aF48EfXU0RTtZAGKtG4GPDv3q ++bYc5TJ2pQzs9y5Bk/jAMR/QQw8CKglBsn1cjYkKViEYEExECAAYFAlImAl0ACgkQ ++OzARt2udZSO5yACgr6Ei7QZ+PAmg4Mr5db+4M3aepAEAniU33RaTKBCGkwQi6kHr ++4VaII2/E ++=l8DH ++-----END PGP PUBLIC KEY BLOCK----- +Index: libguestfs-1.26.10/configure.ac +=================================================================== +--- libguestfs-1.26.10.orig/configure.ac ++++ libguestfs-1.26.10/configure.ac +@@ -1635,6 +1635,7 @@ AC_CONFIG_FILES([Makefile + bash/Makefile + builder/Makefile + builder/libguestfs.conf ++ builder/opensuse.conf + builder/test-config/virt-builder/repos.d/test-index.conf + builder/test-website/virt-builder/repos.d/libguestfs.conf + builder/website/Makefile diff --git a/libguestfs.changes b/libguestfs.changes index fb0fd43..e0832ec 100644 --- a/libguestfs.changes +++ b/libguestfs.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Mon Sep 7 13:39:57 UTC 2015 - cbosdonnat@suse.com + +- Add opensuse images source for virt-builder. + fate#318952. + ------------------------------------------------------------------- Tue Jul 28 13:53:53 UTC 2015 - cbosdonnat@suse.com diff --git a/libguestfs.spec b/libguestfs.spec index bf4209c..0e90ab0 100644 --- a/libguestfs.spec +++ b/libguestfs.spec @@ -1,7 +1,7 @@ # # spec file for package libguestfs # -# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2015 SUSE LINUX Products GmbH, Nuernberg, Germany. # Copyright (c) 2011 Michal Hrusecky # # All modifications and additions to the file contributed by third parties From 676eaa87445fbf08c2d97a776c3402c8ff5e7dac1b81f2b720d70b77499dbe22 Mon Sep 17 00:00:00 2001 From: Olaf Hering Date: Tue, 8 Sep 2015 07:58:58 +0000 Subject: [PATCH 2/3] Accepting request 329627 from home:cbosdonnat:branches:Virtualization Forgot to add curl's --max-redirs 5 together with -L OBS-URL: https://build.opensuse.org/request/show/329627 OBS-URL: https://build.opensuse.org/package/show/Virtualization/libguestfs?expand=0&rev=344 --- 0000-hotfix.patch | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/0000-hotfix.patch b/0000-hotfix.patch index 36bd1b5..c5ae2a7 100644 --- a/0000-hotfix.patch +++ b/0000-hotfix.patch @@ -55,7 +55,7 @@ Index: libguestfs-1.26.10/builder/downloader.ml | _ -> (* Any other protocol. *) (* Get the status code first to ensure the file exists. *) - let cmd = sprintf "%s%s -g -o /dev/null -I -w '%%{http_code}' %s" -+ let cmd = sprintf "%s%s -L -g -o /dev/null -I -w '%%{http_code}' %s" ++ let cmd = sprintf "%s%s -L --max-redirs 5 -g -o /dev/null -I -w '%%{http_code}' %s" t.curl (if t.verbose then "" else " -s -S") (quote uri) in @@ -64,7 +64,7 @@ Index: libguestfs-1.26.10/builder/downloader.ml (* Now download the file. *) - let cmd = sprintf "%s%s -g -o %s %s" -+ let cmd = sprintf "%s%s -L -g -o %s %s" ++ let cmd = sprintf "%s%s -L --max-redirs 5 -g -o %s %s" t.curl (if t.verbose then "" else if progress_bar then " -#" else " -s -S") (quote filename_new) (quote uri) in From 7a9cb2da14bc280eead5c7f0b1be1a46b9bf2b79b83d500c32b3f637dcf423e2 Mon Sep 17 00:00:00 2001 From: Olaf Hering Date: Wed, 9 Sep 2015 14:19:14 +0000 Subject: [PATCH 3/3] Accepting request 330059 from home:cbosdonnat:branches:Virtualization - Define SHA512 as the default password encryption method for opensuse 11+. OBS-URL: https://build.opensuse.org/request/show/330059 OBS-URL: https://build.opensuse.org/package/show/Virtualization/libguestfs?expand=0&rev=345 --- 0000-hotfix.patch | 14 ++++++++++++++ libguestfs.changes | 6 ++++++ 2 files changed, 20 insertions(+) diff --git a/0000-hotfix.patch b/0000-hotfix.patch index c5ae2a7..0c62559 100644 --- a/0000-hotfix.patch +++ b/0000-hotfix.patch @@ -140,3 +140,17 @@ Index: libguestfs-1.26.10/configure.ac builder/test-config/virt-builder/repos.d/test-index.conf builder/test-website/virt-builder/repos.d/libguestfs.conf builder/website/Makefile +Index: libguestfs-1.26.10/customize/password.ml +=================================================================== +--- libguestfs-1.26.10.orig/customize/password.ml ++++ libguestfs-1.26.10/customize/password.ml +@@ -166,6 +166,9 @@ and default_crypto ~prog g root = + | "ubuntu", v when v >= 10 -> `SHA512 + | "ubuntu", _ -> `MD5 + ++ | "opensuse", v when v >= 11 -> `SHA512 ++ | "opensuse", _ -> `MD5 ++ + | _, _ -> + warning ~prog (f_"password: using insecure md5 password encryption for + guest of type %s version %d.\nIf this is incorrect, use --password-crypto option and file a bug.") distro major; diff --git a/libguestfs.changes b/libguestfs.changes index e0832ec..003a0bd 100644 --- a/libguestfs.changes +++ b/libguestfs.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Wed Sep 9 12:50:11 UTC 2015 - cbosdonnat@suse.com + +- Define SHA512 as the default password encryption method for + opensuse 11+. + ------------------------------------------------------------------- Mon Sep 7 13:39:57 UTC 2015 - cbosdonnat@suse.com