ACC SHELL
/**
* File: clients/inst_autoimage.ycp
* Package: Auto-installation
* Author: Anas Nashif <nashif@suse.de>
* Summary: Imaging
*
* $Id: inst_autoimage.ycp 60816 2010-02-15 14:48:39Z ug $
*/
{
textdomain "autoinst";
import "Installation";
import "Progress";
import "Report";
import "AutoinstImage";
import "AutoinstSoftware";
import "AutoinstScripts";
import "AutoinstConfig";
include "autoinstall/io.ycp";
AutoinstScripts::Write("postpartitioning-scripts", false);
if (!AutoinstSoftware::imaging)
return `auto;
string help_text = _("<p>
Please wait while the image is retrieved.</p>
");
list<string> progress_stages =
[
_("Retrieve Image File"),
_("Install image file")
];
list<string> progress_descriptions =
[
_("Retrieving image file..."),
_("Installing image file...")
];
Progress::New(
_("Installing image into system..."),
"", // progress_title
size( progress_stages ), // progress bar length
progress_stages,
progress_descriptions,
help_text );
Progress::NextStage();
//if (!AutoinstImage::Get(AutoinstSoftware::ft_module, Installation::destdir ))
//{
// Report::Error(_("Error while retrieving image."));
// return `abort;
//}
while( !AutoinstImage::getScript() ) {
Report::Error( sformat( _("fetching image-script failed:\n%1"), GET_error) );
}
while( AutoinstImage::runScript() != 0 ) {
string output = (string)SCR::Read (.target.string, "/tmp/ayast_image.log");
Report::Error( sformat( _("running image-script failed:\n%1"), output ) );
}
Progress::Finish();
return `next;
}
ACC SHELL 2018