Ver código fonte

optimize run_command

supeng 4 meses atrás
pai
commit
a1bc8a3351
1 arquivos alterados com 1 adições e 0 exclusões
  1. 1 0
      longvideoapi/utils.py

+ 1 - 0
longvideoapi/utils.py

@@ -352,6 +352,7 @@ def run_command(ecs_client, instance_ids, command):
         request.set_Type("RunShellScript")
         request.set_CommandContent(command)
         request.set_InstanceIds(instance_id_list)
+        request.set_Timeout(180)
         response = send_request(ecs_client=ecs_client, request=request)
         logging.info(f"run_command count:{len(instance_id_list)} instance_id_list:{instance_id_list} response:{response}")