* Fixed a bug in anvil-daemon where a stray 'die' from earlier work was left in.

* Fixed a bug where a double-equal in anvil-configure-striker was causing it not to compile and run.

Signed-off-by: Digimer <digimer@alteeve.ca>
main
Digimer 6 years ago
parent d3d28d8ec5
commit e15fd19ee4
  1. 3
      notes
  2. 7
      tools/anvil-configure-striker
  3. 6
      tools/anvil-daemon
  4. 4
      tools/anvil-maintenance-mode

@ -1,6 +1,3 @@
What if I simply add a flag to Database->write to refresh 'sys::database::timestamp' and not round it?
Then things like 'update_job' could ask for the date to be updated and keep all the records unique?
DB stuff;
Dump;

@ -192,8 +192,11 @@ sub reconfigure_network
}});
# Set the hostname
my ($hostname, $descriptive_hostname) = = $anvil->System->hostname({set => $new_hostname, pretty => $pretty_hostname, debug => 3});
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 3, list => { hostname => $hostname }});
my ($hostname, $descriptive_hostname) = $anvil->System->hostname({set => $new_hostname, pretty => $pretty_hostname, debug => 3});
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 3, list => {
hostname => $hostname,
descriptive_hostname => $descriptive_hostname,
}});
if ($hostname eq $new_hostname)
{
# Success

@ -489,8 +489,8 @@ sub run_jobs
# Start the job, appending '--job-uuid' to the command.
my $command = $job_command." --job-uuid ".$job_uuid;
$anvil->Log->entry({source => $THIS_FILE, line => __LINE__, level => 1, secure => 0, key => "log_0210", variables => { command => $command }});
die;
$anvil->data->{jobs}{handles}{$job_uuid} = $anvil->System->call({
debug => 3,
background => 1,
stdout_file => "/tmp/anvil.job.".$job_uuid.".stdout",
stderr_file => "/tmp/anvil.job.".$job_uuid.".stderr",
@ -498,11 +498,11 @@ sub run_jobs
source => $THIS_FILE,
line => __LINE__,
});
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 3, list => { "jobs::handles::${job_uuid}" => $anvil->data->{jobs}{handles}{$job_uuid} }});
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 2, list => { "jobs::handles::${job_uuid}" => $anvil->data->{jobs}{handles}{$job_uuid} }});
# Log the PID (the job should update the database).
my $pid = $anvil->data->{jobs}{handles}{$job_uuid}->pid();
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 3, list => { pid => $pid }});
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 2, list => { pid => $pid }});
}
}

@ -45,9 +45,9 @@ if (not $anvil->data->{sys}{database}{connections})
}
my $maintenance_mode = $anvil->System->maintenance_mode({debug => 3});
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 2, list => { maintenance_mode => $maintenance_mode }});
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 3, list => { maintenance_mode => $maintenance_mode }});
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 2, list => { "switches::set" => $anvil->data->{switches}{set} }});
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 3, list => { "switches::set" => $anvil->data->{switches}{set} }});
if ($anvil->data->{switches}{set} eq "1")
{
# Enable

Loading…
Cancel
Save