Updated Striker to allow the DR host to not have an IP assisned.

Signed-off-by: Digimer <digimer@alteeve.ca>
main
Digimer 3 years ago
parent a633ab7f63
commit 831abd1981
  1. 2
      Anvil/Tools/System.pm
  2. 9
      cgi-bin/striker

@ -1887,7 +1887,7 @@ LIMIT 1
if (not $has_ipmi)
{
# Return
$anvil->Log->entry({source => $THIS_FILE, line => __LINE__, level => 1, priority => "err", key => "log_0499"});
$anvil->Log->entry({source => $THIS_FILE, line => __LINE__, level => 2, priority => "err", key => "log_0499"});
return(0);
}

@ -65,7 +65,7 @@ if (not -e $anvil->data->{path}{data}{host_uuid})
print_and_exit($anvil);
}
$anvil->Database->connect({debug => 2});
$anvil->Database->connect({debug => 3});
$anvil->Log->entry({source => $THIS_FILE, line => __LINE__, level => 2, secure => 0, key => "log_0132"});
if (not $anvil->data->{sys}{database}{connections})
{
@ -3500,7 +3500,12 @@ sub sanity_check_manifest_step3
# Is the IP valid?
if (not $anvil->Validate->ipv4({ip => $anvil->data->{cgi}{$machine_ip_key}{value}, debug => 2}))
{
# Bad subnet
# Bad subnet. If this is DR IFN 1, and the value was empty, ignore it
# as there simply is no DR on this cluster.
if (($machine eq "dr1") && ($anvil->data->{cgi}{$machine_ip_key}{value} eq ""))
{
next;
}
my $say_network = "#!string!striker_0255!#";
if ($machine eq "node2") { $say_network = "#!string!striker_0256!#"; }
elsif ($machine eq "dr1") { $say_network = "#!string!striker_0257!#"; }

Loading…
Cancel
Save