New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
saving y2logs after the installation has been finished #470
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would check whether save_y2logs
is available or not before trying to execute it. Additionally, I would like to see some test. I am fine if you just move this code to a separate function and write a test only for that function (especially after adding support -if needed- to handle the case where the script is not available).
However, is this code is used during 1st stage too? In that case, we should put it in some common place. What do you think? (Some helper or just a simple client that you call with WFM.CallFunction
, I am not sure).
src/clients/inst_autoconfigure.rb
Outdated
@@ -349,6 +350,11 @@ def main | |||
# Invoke SnapshotsFinish client to perform snapshots (if needed) | |||
WFM.CallFunction("snapshots_finish", ["Write"]) | |||
|
|||
if ProductFeatures.GetBooleanFeature("globals", "save_y2logs") | |||
Yast::SCR.Execute(Yast::Path.new(".target.bash"), | |||
"/usr/sbin/save_y2logs '#{Yast::Directory.logdir}/yast-installation-logs.tar.xz'") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can it happen that save_y2logs
is not installed?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The package dependencies require it.
✔️ Public Jenkins job #12 successfully finished |
✔️ Internal Jenkins job #12 successfully finished |
No description provided.