private function doRun() { if ($this->util->isMigration()) { $this->storeSilent(); // Set silent mode variables require_once "../wizard/steps/services.php"; // configuration to read the ini path $wizServices = new services(); foreach ($wizServices->getServices() as $serviceName) { $className = OS . $serviceName; require_once "../wizard/lib/services/service.php"; require_once "../wizard/lib/services/" . OS . "Service.php"; require_once "../wizard/lib/services/{$className}.php"; $aService = new $className(); $aService->load(); // Load Defaults $aService->start(); // Start Service $status = $aService->status(); // Get service status if ($status) { $this->temp_variables[$serviceName . "Status"] = 'tick'; } else { $this->temp_variables[$serviceName . "Status"] = 'cross_orange'; $this->servicesCheck = 'cross_orange'; } } $this->migrateCheck = true; } return true; }
private function checkServices() { $services = new services(); foreach ($services->getServices() as $serviceName) { $className = OS . $serviceName; $service = new $className(); if ($service->status() == 'RUNNING' || $service->status() == 'STARTED') { $this->temp_variables[$serviceName . "Status"] = 'tick'; } else { $this->temp_variables[$serviceName . "Status"] = 'cross_orange'; $this->services_check = 'cross_orange'; } } return true; }
/** * Check if all services are deactivated * */ private function checkServices() { $services = new services(); foreach ($services->getServices() as $serviceName) { $className = OS . $serviceName; $service = new $className(); $service->load(); $status = $services->serviceStarted($service); if ($status) { $this->temp_variables[$serviceName . "Status"] = 'tick'; } else { $this->temp_variables[$serviceName . "Status"] = 'cross_orange'; $this->services_check = 'cross_orange'; } } return true; }
public function loadInstallServices() { require_once "../wizard/steps/services.php"; $s = new services(); return $s->getServices(); }