From 5a43e7a2ea0cf7af35c100cb67e4a53566cbc496 Mon Sep 17 00:00:00 2001
From: tbrehm <t.brehm@ispconfig.org>
Date: Fri, 03 Feb 2012 05:58:01 -0500
Subject: [PATCH] - Implemented new backup and restore functions for websites and databases (see also FS#1389) - Added "actions" framework in server to replace the functions provided by the core modules - Moved system update function from remoteactins core module to software update plugin.
---
server/server.php | 33 ++++++++++++++++-----------------
1 files changed, 16 insertions(+), 17 deletions(-)
diff --git a/server/server.php b/server/server.php
index 869a621..3683f19 100644
--- a/server/server.php
+++ b/server/server.php
@@ -144,27 +144,26 @@
$tmp_num_records = $tmp_rec['number'];
unset($tmp_rec);
-
+
+ //** Load required base-classes
+ $app->uses('modules,plugins,file,services');
+ //** Load the modules that are in the mods-enabled folder
+ $app->modules->loadModules('all');
+ //** Load the plugins that are in the plugins-enabled folder
+ $app->plugins->loadPlugins('all');
if ($tmp_num_records > 0) {
- /*
- There is something to do, triggert by the database -> do it!
- */
- // Write the Log
$app->log("Found $tmp_num_records changes, starting update process.", LOGLEVEL_DEBUG);
- // Load required base-classes
- $app->uses('modules,plugins,file,services');
- // Load the modules that are in the mods-enabled folder
- $app->modules->loadModules('all');
- // Load the plugins that are in the plugins-enabled folder
- $app->plugins->loadPlugins('all');
- // Go through the sys_datalog table and call the processing functions
- // from the modules that are hooked on to the table actions
+ //** Go through the sys_datalog table and call the processing functions
+ //** from the modules that are hooked on to the table actions
$app->modules->processDatalog();
- // Restart services that need to after configuration
- $app->services->processDelayedActions();
- // All modules are already loaded and processed, so there is NO NEED to load the core once again...
- $needStartCore = false;
}
+ //** Process actions from sys_remoteaction table
+ $app->modules->processActions();
+ //** Restart services that need to after configuration
+ $app->services->processDelayedActions();
+ //** All modules are already loaded and processed, so there is NO NEED to load the core once again...
+ $needStartCore = false;
+
} else {
if ($app->db->connect->connect_error == NULL) {
$app->log('Unable to connect to local server.' . $app->db->errorMessage, LOGLEVEL_WARN);
--
Gitblit v1.9.1