Skip to content

Commit

Permalink
Detect end of agama auto-installation in s390x using for example logs
Browse files Browse the repository at this point in the history
  • Loading branch information
hjluo committed Oct 21, 2024
1 parent 0ef13d5 commit b6ac71f
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 0 deletions.
13 changes: 13 additions & 0 deletions data/yam/agama/auto/b.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"product": {
"id": "Tumbleweed"
},
"user": {
"fullName": "Bernhard M. Wiedemann",
"password": "nots3cr3t",
"userName": "bernhard"
},
"root": {
"password": "nots3cr3t"
}
}
22 changes: 22 additions & 0 deletions lib/Yam/Agama/Pom/RebootTextmodePage.pm
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,26 @@ sub reboot {
enter_cmd 'reboot';
}

sub expect_is_shown {
my ($self, %args) = @_;
# my $timeout = $args{timeout};
my $timeout = 7200;
# my $s3270 = console('x3270');
# my $r;

while (1) {
# script_run('agama logs store');
script_run('tail /var/log/YaST2/y2log');
script_run('tail /var/log/zypper.log');
script_run('agama logs list');
script_run('journalctl -u agama');
script_run('journalctl -u agama-auto');

die "timeout ($timeout) hit on during installation" if $timeout <= 0;
$timeout -= 30;
diag("left total timeout: $timeout");
next;
}
}

1;

0 comments on commit b6ac71f

Please sign in to comment.