[manage.py] Add 0.25s sleep when downing stack

This commit is contained in:
Viyurz 2024-10-16 18:44:58 +02:00
parent 8d90a4d6c7
commit b63ef133c2
Signed by: Viyurz
SSH key fingerprint: SHA256:IskOHTmhHSJIvAt04N6aaxd5SZCVWW1Guf9tEcxIMj8

View file

@ -1,6 +1,6 @@
#!/usr/bin/python3
import os, sys, re, shutil
import os, sys, re, shutil, time
import filecmp
from glob import glob
from mako.template import Template
@ -343,6 +343,7 @@ def upProj(project):
if runPodman("pod", ["exists", f"pod_{project}"]).returncode == 0:
print(f"Tearing down stack for project {project}.")
runPodman("compose", ["-f", f"projects/{project}/compose.yaml.rendered", "down"])
time.sleep(0.25) # Give time to pasta to unbind port
print(f"Creating & starting stack for project {project}.")
runPodman("compose", ["-f", f"projects/{project}/compose.yaml.rendered", "up", "-d"])