fix ci and make macos service time check more aggressive
This commit is contained in:
		
							parent
							
								
									137f58a84a
								
							
						
					
					
						commit
						adf0226641
					
				| @ -1395,8 +1395,8 @@ pub fn install_service() -> bool { | |||||||
|         "{cp} systemctl enable {app_name}; systemctl stop {app_name}; systemctl start {app_name};" |         "{cp} systemctl enable {app_name}; systemctl stop {app_name}; systemctl start {app_name};" | ||||||
|     )) { |     )) { | ||||||
|         Config::set_option("stop-service".into(), "Y".into()); |         Config::set_option("stop-service".into(), "Y".into()); | ||||||
|         return true; |  | ||||||
|     } |     } | ||||||
|  |     true | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| fn check_if_stop_service() { | fn check_if_stop_service() { | ||||||
|  | |||||||
| @ -516,7 +516,7 @@ pub fn start_os_service() { | |||||||
|             server = get_server_start_time(&mut sys, &path); |             server = get_server_start_time(&mut sys, &path); | ||||||
|         } |         } | ||||||
|         if let Some((start_time, pid)) = server { |         if let Some((start_time, pid)) = server { | ||||||
|             if my_start_time <= start_time { |             if my_start_time <= start_time + 1 { | ||||||
|                 log::error!( |                 log::error!( | ||||||
|                     "Agent start later, {my_start_time} vs {start_time}, will restart --service to make delegate work", |                     "Agent start later, {my_start_time} vs {start_time}, will restart --service to make delegate work", | ||||||
|                 ); |                 ); | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user