[yast-commit] [ci_new_pac] JFYI yast2 -> sle12
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 -> sle12 ## BNC# 870803 : "Internal error: Cannot import namespace "Service manager"" (RESOLVED/FIXED) Changes: -------- --- /work/SRC/SUSE:SLE-12:GA/yast2/yast2.changes 2014-03-28 12:00:32.000000000 +0100 +++ /mounts/work_src_done/SLE12/yast2/yast2.changes 2014-03-28 14:28:50.000000000 +0100 @@ -1,0 +2,13 @@ +Fri Mar 28 13:13:54 UTC 2014 - vmoravec@suse.com + +- Add more systemd unit commands to SystemdService +- 3.1.34 + +------------------------------------------------------------------- +Fri Mar 28 13:07:16 UTC 2014 - vmoravec@suse.com + +- Don't change service name which might be frozen string + (bnc#870803) +- 3.1.33 + +------------------------------------------------------------------- calling whatdependson for sle12-i586 Packages directly triggered for rebuild: - yast2 - at least 73 other packages ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/SUSE:SLE-12:GA/yast2 (Old) and /mounts/work_src_done/SLE12/yast2 (BS:build ID:35135 MAIL:yast-commit@opensuse.org) (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Package is "yast2", Maintainer is "yast-commit@opensuse.org" Old: ---- yast2-3.1.32.tar.bz2 New: ---- yast2-3.1.34.tar.bz2 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ yast2.spec ++++++ --- /var/tmp/diff_new_pack.ukIcTG/_old 2014-03-28 16:28:54.000000000 +0100 +++ /var/tmp/diff_new_pack.ukIcTG/_new 2014-03-28 16:28:54.000000000 +0100 @@ -17,7 +17,7 @@ Name: yast2 -Version: 3.1.32 +Version: 3.1.34 Release: 0 URL: https://github.com/yast/yast-yast2 ++++++ yast2-3.1.32.tar.bz2 -> yast2-3.1.34.tar.bz2 ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-3.1.32/library/runlevel/src/modules/Service.rb new/yast2-3.1.34/library/runlevel/src/modules/Service.rb --- old/yast2-3.1.32/library/runlevel/src/modules/Service.rb 2014-03-28 11:28:36.000000000 +0100 +++ new/yast2-3.1.34/library/runlevel/src/modules/Service.rb 2014-03-28 14:20:52.000000000 +0100 @@ -313,7 +313,7 @@ # @param [String] param init script argument # @return [Fixnum] exit value def RunInitScript name, param - deprecate("use `start` or `stop` instead") + deprecate("use the specific unit command instead") service = SystemdService.find(name) if !service @@ -321,16 +321,22 @@ return -1 end - case param - when 'start' - service.start - when 'stop' - service.stop - else - log.error "Unknown action '#{param}' for service '#{name}'" - return -1 - end - 0 + result = + case param + when 'start', 'stop', 'status', 'reload', 'restart', 'enable', 'disable' + service.send(param) + when 'try-restart' + service.try_restart + when 'reload-or-restart' + service.reload_or_restart + when 'reload-or-try-restart' + service.reload_or_try_restart + else + log.error "Unknown action '#{param}' for service '#{name}'" + false + end + + result ? 0 : -1 end # @deprecated Use specific unit methods for service configuration diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-3.1.32/library/systemd/src/lib/yast2/systemd_unit.rb new/yast2-3.1.34/library/systemd/src/lib/yast2/systemd_unit.rb --- old/yast2-3.1.32/library/systemd/src/lib/yast2/systemd_unit.rb 2014-03-28 11:28:36.000000000 +0100 +++ new/yast2-3.1.34/library/systemd/src/lib/yast2/systemd_unit.rb 2014-03-28 14:20:52.000000000 +0100 @@ -101,10 +101,22 @@ run_command! { command("restart") } end + def try_restart + run_command! { command("try-restart") } + end + def reload run_command! { command("reload") } end + def reload_or_restart + run_command! { command("reload-or-restart") } + end + + def reload_or_try_restart + run_command! { command("reload-or-try-restart") } + end + def command command_name, options={} Systemctl.execute("#{command_name} #{unit_name}.#{unit_type} #{options[:options]}") end diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-3.1.32/library/systemd/src/modules/systemd_service.rb new/yast2-3.1.34/library/systemd/src/modules/systemd_service.rb --- old/yast2-3.1.32/library/systemd/src/modules/systemd_service.rb 2014-03-28 11:28:36.000000000 +0100 +++ new/yast2-3.1.34/library/systemd/src/modules/systemd_service.rb 2014-03-28 14:20:52.000000000 +0100 @@ -75,7 +75,7 @@ UNIT_SUFFIX = ".service" def find service_name, properties={} - service_name << UNIT_SUFFIX unless service_name.end_with?(UNIT_SUFFIX) + service_name += UNIT_SUFFIX unless service_name.end_with?(UNIT_SUFFIX) service = Service.new(service_name, properties) return nil if service.properties.not_found? service diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-3.1.32/library/systemd/src/modules/systemd_target.rb new/yast2-3.1.34/library/systemd/src/modules/systemd_target.rb --- old/yast2-3.1.32/library/systemd/src/modules/systemd_target.rb 2014-03-28 11:28:36.000000000 +0100 +++ new/yast2-3.1.34/library/systemd/src/modules/systemd_target.rb 2014-03-28 14:20:52.000000000 +0100 @@ -47,7 +47,7 @@ PROPERTIES = { :allow_isolate => "AllowIsolate" } def find target_name, properties={} - target_name << UNIT_SUFFIX unless target_name.end_with?(UNIT_SUFFIX) + target_name += UNIT_SUFFIX unless target_name.end_with?(UNIT_SUFFIX) target = Target.new(target_name, PROPERTIES.merge(properties)) return nil if target.properties.not_found? target diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-3.1.32/library/systemd/test/systemd_unit_test.rb new/yast2-3.1.34/library/systemd/test/systemd_unit_test.rb --- old/yast2-3.1.32/library/systemd/test/systemd_unit_test.rb 2014-03-28 11:28:36.000000000 +0100 +++ new/yast2-3.1.34/library/systemd/test/systemd_unit_test.rb 2014-03-28 14:20:52.000000000 +0100 @@ -6,6 +6,7 @@ module Yast describe SystemdUnit do include SystemdSocketStubs + include SystemdServiceStubs def trigger_reloading_properties command unit = SystemdUnit.new("new.socket") @@ -16,6 +17,7 @@ before do stub_sockets + stub_services end describe "#properties" do @@ -159,6 +161,71 @@ end end + describe "#restart" do + it "returns true if unit has been restarted" do + unit = SystemdUnit.new("sshd.service") + expect(unit.restart).to be_true + end + + it "returns false if the restart fails" do + stub_unit_command(:success=>false) + unit = SystemdUnit.new("sshd.service") + expect(unit.restart).to be_false + end + end + + describe "#try_restart" do + it "returns true if the unit has been restarted" do + unit = SystemdUnit.new("sshd.service") + expect(unit.try_restart).to be_true + end + + it "returns false if the try_restart fails" do + stub_unit_command(:success=>false) + unit = SystemdUnit.new("sshd.service") + expect(unit.try_restart).to be_false + end + end + + describe "#reload" do + it "returns true if the unit has been reloaded" do + unit = SystemdUnit.new("sshd.service") + expect(unit.reload).to be_true + end + + it "returns false if the reload fails" do + stub_unit_command(:success=>false) + unit = SystemdUnit.new("sshd.service") + expect(unit.reload).to be_false + end + end + + describe "#reload_or_restart" do + it "returns true if the unit has been reloaded or restarted" do + unit = SystemdUnit.new("sshd.service") + expect(unit.reload_or_restart).to be_true + end + + it "returns false if the reload_or_restart action fails" do + stub_unit_command(:success=>false) + unit = SystemdUnit.new("sshd.service") + expect(unit.reload_or_restart).to be_false + end + end + + describe "#reload_or_try_restart" do + it "returns true if the unit has been reload_or_try_restarted" do + unit = SystemdUnit.new("sshd.service") + expect(unit.reload_or_try_restart).to be_true + end + + it "returns false if the reload_or_try_restart action fails" do + stub_unit_command(:success=>false) + unit = SystemdUnit.new("sshd.service") + expect(unit.reload_or_try_restart).to be_false + end + end + describe "#error" do it "returns empty string if the unit commands succeed" do stub_unit_command(:success=>true) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-3.1.32/library/systemd/test/test_helper.rb new/yast2-3.1.34/library/systemd/test/test_helper.rb --- old/yast2-3.1.32/library/systemd/test/test_helper.rb 2014-03-28 11:28:36.000000000 +0100 +++ new/yast2-3.1.34/library/systemd/test/test_helper.rb 2014-03-28 14:20:52.000000000 +0100 @@ -99,7 +99,7 @@ .stub(:command) .and_return( OpenStruct.new \ - :stdout => 'success', + :stdout => '', :stderr => ( success ? '' : 'failure'), :exit => ( success ? 0 : 1 ) ) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-3.1.32/package/yast2.changes new/yast2-3.1.34/package/yast2.changes --- old/yast2-3.1.32/package/yast2.changes 2014-03-28 11:28:36.000000000 +0100 +++ new/yast2-3.1.34/package/yast2.changes 2014-03-28 14:20:52.000000000 +0100 @@ -1,4 +1,17 @@ ------------------------------------------------------------------- +Fri Mar 28 13:13:54 UTC 2014 - vmoravec@suse.com + +- Add more systemd unit commands to SystemdService +- 3.1.34 + +------------------------------------------------------------------- +Fri Mar 28 13:07:16 UTC 2014 - vmoravec@suse.com + +- Don't change service name which might be frozen string + (bnc#870803) +- 3.1.33 + +------------------------------------------------------------------- Thu Mar 27 10:15:12 UTC 2014 - vmoravec@suse.com - Fix for template systemd units properties diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-3.1.32/package/yast2.spec new/yast2-3.1.34/package/yast2.spec --- old/yast2-3.1.32/package/yast2.spec 2014-03-28 11:28:36.000000000 +0100 +++ new/yast2-3.1.34/package/yast2.spec 2014-03-28 14:20:52.000000000 +0100 @@ -17,7 +17,7 @@ Name: yast2 -Version: 3.1.32 +Version: 3.1.34 Release: 0 URL: https://github.com/yast/yast-yast2 continue with "q"... Checked in at Fri Mar 28 16:29:20 CET 2014 by ro Remember to have fun... -- To unsubscribe, e-mail: yast-commit+unsubscribe@opensuse.org For additional commands, e-mail: yast-commit+help@opensuse.org
participants (1)
-
ro