فهرست منبع

Testing Custom Console File Backup and Size Check

own3mall 7 سال پیش
والد
کامیت
9301a43f10
4فایلهای تغییر یافته به همراه10 افزوده شده و 7 حذف شده
  1. 4 4
      includes/lib_remote.php
  2. 2 1
      modules/gamemanager/home_handling_functions.php
  3. 2 1
      modules/gamemanager/restart_server.php
  4. 2 1
      ogp_api.php

+ 4 - 4
includes/lib_remote.php

@@ -381,13 +381,13 @@ class OGPRemoteLibrary
 						$home_id, $home_path, $server_ip, $server_port, $exec_path, $exec_folder_path,
 						$control_protocol, $control_password, $control_type,
 						$appId, $modname, $betaname, $betapwd, $user, $pass, $guard, $precmd, $postcmd, $cfg_os, $filesToLockUnlock,
-						$startup_cmd, $cpu, $nice, $preStart, $envVars, $game_key, $archBits
+						$startup_cmd, $cpu, $nice, $preStart, $envVars, $game_key, $archBits, $console_log = ""
 	)
 	{
 		$params = $this->encrypt_params($home_id, $home_path, $server_ip, $server_port, $exec_path, $exec_folder_path,
 						$control_protocol, $control_password, $control_type,
 						$appId, $modname, $betaname, $betapwd, $user, $pass, $guard, $precmd, $postcmd, $cfg_os, $filesToLockUnlock,
-						$startup_cmd, $cpu, $nice, $preStart, $envVars, $game_key, $archBits);
+						$startup_cmd, $cpu, $nice, $preStart, $envVars, $game_key, $archBits, $console_log);
 
 		$this->add_enc_chk($params);
 		$request = xmlrpc_encode_request("automatic_steam_update", $params);
@@ -724,11 +724,11 @@ class OGPRemoteLibrary
 
 	public function remote_restart_server($home_id,$server_ip,$server_port, 
 			$control_protocol,$control_password,$control_type,
-			$home_path,$server_exe,$run_dir,$cmd,$cpu,$nice,$preStart, $envVars, $game_key)
+			$home_path,$server_exe,$run_dir,$cmd,$cpu,$nice,$preStart, $envVars, $game_key, $console_log = "")
 	{
 		$params_array = $this->encrypt_params($home_id,$server_ip,$server_port,
 			$control_protocol,$control_password,$control_type,
-			$home_path,$server_exe,$run_dir,$cmd,$cpu,$nice,$preStart,$envVars, $game_key);
+			$home_path,$server_exe,$run_dir,$cmd,$cpu,$nice,$preStart,$envVars, $game_key, $console_log);
 		$this->add_enc_chk($params_array);
 		$request = xmlrpc_encode_request("restart_server", $params_array);
 

+ 2 - 1
modules/gamemanager/home_handling_functions.php

@@ -338,7 +338,8 @@ function exec_operation( $action, $home_id, $mod_id, $ip, $port )
 														$home_info['mods'][$mod_id]['nice'],
 														$preStart,
 														$envVars,
-														$server_xml->game_key);
+														$server_xml->game_key,
+														(isset( $server_xml->console_log ) ? $server_xml->console_log : ""));
 		$db->logger(get_lang_f('server_restarted', $home_info['home_name']) . "($ip:$port)");
 		if ( $remote_retval === -1 )
 			return FALSE;

+ 2 - 1
modules/gamemanager/restart_server.php

@@ -243,7 +243,8 @@ function exec_ogp_module() {
 			$remote_retval = $remote->remote_restart_server($home_id,$ip,$port,$server_xml->control_protocol,
 															$home_info['control_password'],$control_type,$home_info['home_path'],
 															$server_xml->server_exec_name,$run_dir,$start_cmd,
-															$home_info['cpu_affinity'],$home_info['nice'],$preStart,$envVars, $server_xml->game_key);
+															$home_info['cpu_affinity'],$home_info['nice'],$preStart,$envVars, $server_xml->game_key, 
+															(isset( $server_xml->console_log ) ? $server_xml->console_log : ""));
 			
 			$db->logger(get_lang_f('server_restarted', $home_info['home_name']) . "($ip:$port)");
 				

+ 2 - 1
ogp_api.php

@@ -1054,7 +1054,8 @@ function api_gamemanager()
 														$home_info['mods'][$mod_id]['nice'],
 														$preStart,
 														$envVars,
-														$server_xml->game_key);
+														$server_xml->game_key, 
+														(isset( $server_xml->console_log ) ? $server_xml->console_log : ""));
 		
 		if($remote_retval === -1)
 			return array("status" => '333', "message" => "The server could not be restarted.");