Skip to content

Commit

Permalink
Exclude grub_test in declarative schedule for ext4 in s390x
Browse files Browse the repository at this point in the history
  • Loading branch information
jknphy committed May 15, 2019
1 parent 1f7fae7 commit a23e4ec
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 6 deletions.
15 changes: 12 additions & 3 deletions lib/scheduler.pm
Original file line number Diff line number Diff line change
Expand Up @@ -47,10 +47,19 @@ sub parse_schedule {
my $condition = $schedule->{conditional_schedule}->{$module};
# Iterate over variables in the condition
foreach my $var (keys %{$condition}) {
next unless my $val = get_var($var);
# If value of the variable matched the conditions
my $setting = $condition->{$var};
my $value_list;
foreach my $val (keys %{$setting}) {
# Get list of test when condition matches and does not try more values
if (get_var($var) eq $val) {
$value_list = $setting->{$val};
last;
}
# Get list of test when 'any' is specified and continue iterating more values
$value_list = $setting->{$val} if ($val eq 'any');
}
# Iterate over the list of the modules to be loaded
push(@scheduled, $_) for (@{$condition->{$var}->{$val}});
push(@scheduled, $_) for (@{$value_list});
}
}
return @scheduled;
Expand Down
7 changes: 4 additions & 3 deletions schedule/ext4.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,12 @@ conditional_schedule:
SYSTEM_ROLE:
default:
- installation/system_role
reconnect_mgmt_console:
after_reboot:
ARCH:
s390x:
- boot/reconnect_mgmt_console
any:
- installation/grub_test
schedule:
- installation/bootloader_start
- installation/welcome
Expand All @@ -38,6 +40,5 @@ schedule:
- installation/await_install
- installation/logs_from_installation_system
- installation/reboot_after_installation
- installation/grub_test
- {{reconnect_mgmt_console}}
- {{after_reboot}}
- installation/first_boot

0 comments on commit a23e4ec

Please sign in to comment.