CI GetContainerHealth(): speed up checks
This commit is contained in:
committed by
Robert Schmidt
parent
d0b637a020
commit
5f1219bc32
@@ -159,12 +159,11 @@ def GetContainerHealth(ssh, containerName):
|
||||
return False
|
||||
if 'db_init' in containerName or 'db-init' in containerName: # exits with 0, there cannot be healthy
|
||||
return True
|
||||
time.sleep(5)
|
||||
for _ in range(3):
|
||||
for _ in range(8):
|
||||
result = ssh.run(f'docker inspect --format="{{{{.State.Health.Status}}}}" {containerName}', silent=True)
|
||||
if result.stdout == 'healthy':
|
||||
return True
|
||||
time.sleep(10)
|
||||
time.sleep(5)
|
||||
return False
|
||||
|
||||
def ExistEnvFilePrint(ssh, wd, prompt='env vars in existing'):
|
||||
|
||||
Reference in New Issue
Block a user