forked from extern/podman-compose
Fix infinite loop
Since we never remove thread from the list of thread, podman-compose up never return as long as 1 thread is alive.
This commit is contained in:
parent
d3f37112a7
commit
105b129b08
@ -1151,12 +1151,13 @@ def compose_up(compose, args):
|
||||
thread.start()
|
||||
threads.append(thread)
|
||||
time.sleep(1)
|
||||
while True:
|
||||
while threads:
|
||||
for thread in threads:
|
||||
thread.join(timeout=1.0)
|
||||
if thread.is_alive(): continue
|
||||
if args.abort_on_container_exit:
|
||||
exit(-1)
|
||||
if not thread.is_alive():
|
||||
threads.remove(thread)
|
||||
if args.abort_on_container_exit:
|
||||
exit(-1)
|
||||
|
||||
@cmd_run(podman_compose, 'down', 'tear down entire stack')
|
||||
def compose_down(compose, args):
|
||||
|
Loading…
Reference in New Issue
Block a user