Island: Fix negative sleep time bug in aws_command_runner
This commit is contained in:
parent
27f8195be5
commit
109ea87196
|
@ -92,8 +92,7 @@ def _wait_for_command_to_complete(
|
||||||
timer.set(REMOTE_COMMAND_TIMEOUT)
|
timer.set(REMOTE_COMMAND_TIMEOUT)
|
||||||
|
|
||||||
while not timer.is_expired():
|
while not timer.is_expired():
|
||||||
sleep_time = min((timer.time_remaining - STATUS_CHECK_SLEEP_TIME), STATUS_CHECK_SLEEP_TIME)
|
time.sleep(STATUS_CHECK_SLEEP_TIME)
|
||||||
time.sleep(sleep_time)
|
|
||||||
|
|
||||||
command_status = aws_client.get_command_invocation(
|
command_status = aws_client.get_command_invocation(
|
||||||
CommandId=command_id, InstanceId=target_instance_id
|
CommandId=command_id, InstanceId=target_instance_id
|
||||||
|
|
Loading…
Reference in New Issue