diff options
author | Jonathan Bauer | 2016-04-01 16:50:13 +0200 |
---|---|---|
committer | Jonathan Bauer | 2016-04-01 16:50:13 +0200 |
commit | dbc0d9614421e064cc62aacf116ebb783c83f2f3 (patch) | |
tree | 091844b8578ff1d9ac18edfd3cee3e63210133d7 /inc/event.inc.php | |
parent | [ldapauth] Add homedir conf to ldap wizard (diff) | |
download | slx-admin-dbc0d9614421e064cc62aacf116ebb783c83f2f3.tar.gz slx-admin-dbc0d9614421e064cc62aacf116ebb783c83f2f3.tar.xz slx-admin-dbc0d9614421e064cc62aacf116ebb783c83f2f3.zip |
[merge] merging c3sl / fr - initial commit
Diffstat (limited to 'inc/event.inc.php')
-rw-r--r-- | inc/event.inc.php | 19 |
1 files changed, 15 insertions, 4 deletions
diff --git a/inc/event.inc.php b/inc/event.inc.php index e014666a..01a148b0 100644 --- a/inc/event.inc.php +++ b/inc/event.inc.php @@ -26,7 +26,8 @@ class Event $mountId = Trigger::mount(); $autoIp = Trigger::autoUpdateServerIp(); $ldadpId = Trigger::ldadp(); - + $ipxeId = Trigger::ipxe(); + Taskmanager::submit('DozmodLauncher', array( 'operation' => 'start' )); @@ -59,6 +60,17 @@ class Event EventLog::failure("The server's IP address could not be determined automatically, and there is no valid address configured."); $everythingFine = false; } + // iPXE generation + if ($ipxeId === false) { + EventLog::failure('Cannot generate PXE menu: Taskmanager unreachable!'); + $everythingFine = false; + } else { + $res = Taskmanager::waitComplete($ipxeId, 5000); + if (Taskmanager::isFailed($res)) { + EventLog::failure('Update PXE Menu failed', $res['data']['error']); + $everythingFine = false; + } + } // Just so we know booting is done (and we don't expect any more errors from booting up) if ($everythingFine) { @@ -73,11 +85,9 @@ class Event */ public static function serverIpChanged() { + error_log('Server ip changed'); global $tidIpxe; $tidIpxe = Trigger::ipxe(); - if (is_string($tidIpxe)) { - TaskmanagerCallback::addCallback($tidIpxe, 'cbIpxeBuilt'); - } ConfigModule::serverIpChanged(); } @@ -86,6 +96,7 @@ class Event */ public static function activeConfigChanged() { + error_log('Active config changed'); $task = Trigger::ldadp(); TaskmanagerCallback::addCallback($task, 'ldadpStartup'); } |