Script 'mail_helper' called by ro
Hello packager,
This is just FYI. Your package was checked in in distribution "sle12"
by autobuild-member: ro.
Here comes the log...
---------------------------%<------------------------------
Hi,
here is the log from ci_new_pac /mounts/work_src_done/SLE12/yast2-update -> sle12
## BNC# 876677 : "Build0353: Upgrade failed due to problems with network and remounting" (NEW/)
## BNC# 882039 : "[UPGRADE] Upgrade process modifies data on installed system and does not restore them" (ASSIGNED/)
## BNC# 884384 : "autoyast upgrade: UI Syntax Error" (RESOLVED/FIXED)
Changes:
--------
--- /work/SRC/SUSE:SLE-12:GA/yast2-update/yast2-update.changes 2014-06-25 17:45:10.000000000 +0200
+++ /mounts/work_src_done/SLE12/yast2-update/yast2-update.changes 2014-07-01 09:59:18.000000000 +0200
@@ -1,0 +2,22 @@
+Tue Jul 1 06:38:02 UTC 2014 - lslezak@suse.cz
+
+- remove all repositories when going back to close the open solv
+ files and allow successful unmount when changing the target
+ partition to update (bnc#876677)
+- 3.1.18
+
+-------------------------------------------------------------------
+Mon Jun 30 14:32:39 UTC 2014 - jreidinger@suse.cz
+
+- Add also restore script to backup to make easier restoring
+ (bnc#882039)
+- 3.1.17
+
+-------------------------------------------------------------------
+Thu Jun 26 16:16:04 CEST 2014 - schubi@suse.de
+
+- Checking if the files exist which have to be backuped by the
+ tar call. (bnc#884384)
+- 3.1.16
+
+-------------------------------------------------------------------
calling whatdependson for sle12-i586
Packages directly triggered for rebuild:
- yast2-product-creator
- yast2-schema
- yast2-update
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/SUSE:SLE-12:GA/yast2-update (Old)
and /mounts/work_src_done/SLE12/yast2-update (BS:build ID:40235 MAIL:yast-commit@opensuse.org) (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "yast2-update", Maintainer is "yast-commit@opensuse.org"
Old:
----
yast2-update-3.1.15.tar.bz2
New:
----
yast2-update-3.1.18.tar.bz2
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ yast2-update.spec ++++++
--- /var/tmp/diff_new_pack.5OWSp6/_old 2014-07-01 13:12:28.000000000 +0200
+++ /var/tmp/diff_new_pack.5OWSp6/_new 2014-07-01 13:12:28.000000000 +0200
@@ -17,7 +17,7 @@
Name: yast2-update
-Version: 3.1.15
+Version: 3.1.18
Release: 0
BuildRoot: %{_tmppath}/%{name}-%{version}-build
++++++ yast2-update-3.1.15.tar.bz2 -> yast2-update-3.1.18.tar.bz2 ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-update-3.1.15/package/yast2-update.changes new/yast2-update-3.1.18/package/yast2-update.changes
--- old/yast2-update-3.1.15/package/yast2-update.changes 2014-06-25 15:56:08.000000000 +0200
+++ new/yast2-update-3.1.18/package/yast2-update.changes 2014-07-01 09:55:07.000000000 +0200
@@ -1,4 +1,26 @@
-------------------------------------------------------------------
+Tue Jul 1 06:38:02 UTC 2014 - lslezak@suse.cz
+
+- remove all repositories when going back to close the open solv
+ files and allow successful unmount when changing the target
+ partition to update (bnc#876677)
+- 3.1.18
+
+-------------------------------------------------------------------
+Mon Jun 30 14:32:39 UTC 2014 - jreidinger@suse.cz
+
+- Add also restore script to backup to make easier restoring
+ (bnc#882039)
+- 3.1.17
+
+-------------------------------------------------------------------
+Thu Jun 26 16:16:04 CEST 2014 - schubi@suse.de
+
+- Checking if the files exist which have to be backuped by the
+ tar call. (bnc#884384)
+- 3.1.16
+
+-------------------------------------------------------------------
Wed Jun 25 11:10:44 UTC 2014 - lslezak@suse.cz
- display product update summary and check for automatic product
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-update-3.1.15/package/yast2-update.spec new/yast2-update-3.1.18/package/yast2-update.spec
--- old/yast2-update-3.1.15/package/yast2-update.spec 2014-06-25 15:56:08.000000000 +0200
+++ new/yast2-update-3.1.18/package/yast2-update.spec 2014-07-01 09:55:07.000000000 +0200
@@ -17,7 +17,7 @@
Name: yast2-update
-Version: 3.1.15
+Version: 3.1.18
Release: 0
BuildRoot: %{_tmppath}/%{name}-%{version}-build
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-update-3.1.15/src/modules/Update.rb new/yast2-update-3.1.18/src/modules/Update.rb
--- old/yast2-update-3.1.15/src/modules/Update.rb 2014-06-25 15:56:08.000000000 +0200
+++ new/yast2-update-3.1.18/src/modules/Update.rb 2014-07-01 09:55:07.000000000 +0200
@@ -802,6 +802,21 @@
#
def Detach
+ # release mounted devices
+ Pkg.SourceReleaseAll
+
+ # remove all repos except the initial installation repository
+ # to close the solv files and allow unmounting the target
+ repos_to_delete = Pkg.SourceGetCurrent(false)
+ repos_to_delete.delete(0)
+ log.info "Removing repositories: #{repos_to_delete}"
+
+ # the changes are not saved to the target system, the repositories
+ # are removed only from pkg-bindings
+ repos_to_delete.each do |repo_to_delete|
+ Pkg.SourceDelete(repo_to_delete)
+ end
+
Pkg.TargetFinish
@did_init1 = false
@did_init2 = false
@@ -842,21 +857,12 @@
def create_backup(name, paths)
mounted_root = Installation.destdir
- # ensure directory exists
- ::FileUtils.mkdir_p(File.join(mounted_root, BACKUP_DIR))
-
- target_file = File.join(mounted_root, BACKUP_DIR, "#{name}.tar.bz2")
-
- paths_without_prefix = paths.map {|p| p.start_with?("/") ? p[1..-1] : p }
-
- command = "tar cjvf '#{target_file}'"
- command << " -C '#{mounted_root}'"
- # no shell escaping here, but we backup reasonable files and want to allow globs
- command << " " + paths_without_prefix.join(" ")
- res = SCR.Execute(path(".target.bash_output"), command)
- log.info "backup created with '#{command}' result: #{res}"
+ tarball_path = File.join(BACKUP_DIR, "#{name}.tar.bz2")
+ root_tarball_path = File.join(mounted_root, tarball_path)
+ create_tarball(root_tarball_path, mounted_root, paths)
- raise "Failed to create backup" if res["exit"] != 0
+ script_path = File.join(mounted_root, BACKUP_DIR, "restore-#{name}.sh")
+ create_restore_script(script_path, tarball_path, paths)
end
publish :variable => :packages_to_install, :type => "integer"
@@ -896,6 +902,53 @@
private
+ def create_tarball(tarball_path, root, paths)
+ # tar reports an error if a file does not exist.
+ # So we have to check this before.
+ existing_paths = paths.select { |p| File.exist?(File.join(root, p)) }
+
+ # ensure directory exists
+ ::FileUtils.mkdir_p(File.dirname(tarball_path))
+
+ paths_without_prefix = existing_paths.map {|p| p.start_with?("/") ? p[1..-1] : p }
+
+ command = "tar cjvf '#{tarball_path}'"
+ command << " -C '#{root}'"
+ # no shell escaping here, but we backup reasonable files and want to allow globs
+ command << " " + paths_without_prefix.join(" ")
+ res = SCR.Execute(path(".target.bash_output"), command)
+ log.info "backup created with '#{command}' result: #{res}"
+
+
+ # tarball can contain sensitive data, so prevent read to non-root
+ # do it for sure even if tar failed as it can contain partial content
+ ::FileUtils.chmod(0600, tarball_path) if File.exist?(tarball_path)
+
+ raise "Failed to create backup" if res["exit"] != 0
+ end
+
+ def create_restore_script(script_path, tarball_path, paths)
+ paths_without_prefix = paths.map {|p| p.start_with?("/") ? p[1..-1] : p }
+
+ # remove leading "/" from tarball to allow to run it from different root
+ tarball_path = tarball_path[1..-1] if tarball_path.start_with?("/")
+ script_content = <