Fix legacy services check names
This commit is contained in:
parent
18cfd175a2
commit
69d85c4236
2 changed files with 15 additions and 14 deletions
|
@ -5,15 +5,15 @@ class Application_Model_Systemstatus
|
|||
public static function GetMonitStatus($p_ip)
|
||||
{
|
||||
$CC_CONFIG = Config::getConfig();
|
||||
// $monit_user = $CC_CONFIG['monit_user'];
|
||||
// $monit_password = $CC_CONFIG['monit_password'];
|
||||
// $monit_user = $CC_CONFIG['monit_user'];
|
||||
// $monit_password = $CC_CONFIG['monit_password'];
|
||||
|
||||
$url = "http://{$p_ip}:2812/_status?format=xml";
|
||||
|
||||
$ch = curl_init();
|
||||
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
|
||||
curl_setopt($ch, CURLOPT_URL, $url);
|
||||
// curl_setopt($ch, CURLOPT_USERPWD, "$monit_user:$monit_password");
|
||||
// curl_setopt($ch, CURLOPT_USERPWD, "$monit_user:$monit_password");
|
||||
//wait a max of 3 seconds before aborting connection attempt
|
||||
curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, 3);
|
||||
$result = curl_exec($ch);
|
||||
|
@ -42,7 +42,8 @@ class Application_Model_Systemstatus
|
|||
'status' => 0,
|
||||
'memory_perc' => '0%',
|
||||
'memory_kb' => '0',
|
||||
'cpu_perc' => '0%', ];
|
||||
'cpu_perc' => '0%',
|
||||
];
|
||||
|
||||
$notMonitored = [
|
||||
'name' => $p_serviceName,
|
||||
|
@ -153,7 +154,7 @@ class Application_Model_Systemstatus
|
|||
|
||||
$docRoot = self::GetMonitStatus($ip);
|
||||
|
||||
return self::ExtractServiceInformation($docRoot, 'airtime-playout');
|
||||
return self::ExtractServiceInformation($docRoot, 'libretime-playout');
|
||||
}
|
||||
|
||||
public static function GetLiquidsoapStatus()
|
||||
|
@ -166,7 +167,7 @@ class Application_Model_Systemstatus
|
|||
|
||||
$docRoot = self::GetMonitStatus($ip);
|
||||
|
||||
return self::ExtractServiceInformation($docRoot, 'airtime-liquidsoap');
|
||||
return self::ExtractServiceInformation($docRoot, 'libretime-liquidsoap');
|
||||
}
|
||||
|
||||
public static function GetMediaMonitorStatus()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue