Added 'system::all::configured' to anvil-join-anvil to mark an explicit end of config.

Started updating striker-initialize-host to handle the new anvil repo config.

Signed-off-by: Digimer <digimer@alteeve.ca>
main
Digimer 2 years ago
parent 596855405f
commit c23c79cdf0
  1. 1
      share/words.xml
  2. 12
      tools/anvil-join-anvil
  3. 11
      tools/striker-initialize-host

@ -3003,6 +3003,7 @@ If you are comfortable that the target has changed for a known reason, you can s
<key name="striker_0294">This indicates if a Striker's DB is available to be used.</key>
<key name="striker_0295">This indicates that this node has had pacemaker configured.</key>
<key name="striker_0296">This indicates that this node or DR host has had base DRBD configured.</key>
<key name="striker_0297">This indicates that this node or DR host has completed all tasks needed to be a full member of the Anvil!.</key>
<!-- These are generally units and appended to numbers -->
<key name="suffix_0001">#!variable!number!#/sec</key>

@ -68,6 +68,18 @@ configure_drbd($anvil);
update_progress($anvil, 100, "job_0128");
$anvil->Log->entry({source => $THIS_FILE, line => __LINE__, 'print' => 1, level => 1, key => "job_0128"});
# Record that we're done configuring pacemaker.
$anvil->Database->insert_or_update_variables({
variable_name => "system::all::configured",
variable_value => 1,
variable_default => "",
variable_description => "striker_0297",
variable_section => "system",
variable_source_uuid => $anvil->data->{sys}{host_uuid},
variable_source_table => "hosts",
});
$anvil->nice_exit({exit_code => 0});
#############################################################################################################

@ -375,6 +375,8 @@ sub add_repos
$anvil->data->{job}{progress} += 5;
update_progress($anvil, $anvil->data->{job}{progress}, "job_0028");
### TODO: Rework this, add $anvil->data->{data}{enterprise_uuid}
# Add the local repo.
my $repo = $anvil->Striker->get_local_repo({debug => 2});
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 2, list => { repo => $repo }});
@ -1015,6 +1017,15 @@ sub get_job_details
$anvil->nice_exit({exit_code => 3});
}
# Set up all possible variables.
$anvil->data->{data}{enterprise_uuid} = "";
$anvil->data->{data}{host_ip_address} = "";
$anvil->data->{data}{password} = "";
$anvil->data->{data}{rh_password} = "";
$anvil->data->{data}{rh_user} = "";
$anvil->data->{data}{ssh_port} = "";
$anvil->data->{data}{type} = "";
$anvil->data->{jobs}{job_uuid} = $anvil->data->{switches}{'job-uuid'};
$anvil->data->{jobs}{job_command} = $return->{job_command};
$anvil->data->{jobs}{job_data} = $return->{job_data};

Loading…
Cancel
Save