From bda020bf5f86d20253f39698c3bb32f8d156de60 Mon Sep 17 00:00:00 2001 From: "John L. Villalovos" Date: Fri, 24 Jun 2022 08:05:43 -0700 Subject: [PATCH] chore(ci): increase timeout for docker container to come online Have been seeing timeout issues more and more. Increase timeout from 200 seconds to 300 seconds (5 minutes). --- tests/functional/conftest.py | 20 ++++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) diff --git a/tests/functional/conftest.py b/tests/functional/conftest.py index e43b53bf4..09cdd6931 100644 --- a/tests/functional/conftest.py +++ b/tests/functional/conftest.py @@ -154,8 +154,13 @@ def check_is_alive(): Return a healthcheck function fixture for the GitLab container spinup. """ - def _check(container): - logging.info("Checking if GitLab container is up...") + def _check(container: str, start_time: float) -> bool: + setup_time = time.perf_counter() - start_time + minutes, seconds = int(setup_time / 60), int(setup_time % 60) + logging.info( + f"Checking if GitLab container is up. " + f"Have been checking for {minutes} minute(s), {seconds} seconds ..." + ) logs = ["docker", "logs", container] return "gitlab Reconfigured!" in check_output(logs).decode() @@ -191,11 +196,18 @@ def gitlab_config(check_is_alive, docker_ip, docker_services, temp_dir, fixture_ config_file = temp_dir / "python-gitlab.cfg" port = docker_services.port_for("gitlab", 80) + start_time = time.perf_counter() logging.info("Waiting for GitLab container to become ready.") docker_services.wait_until_responsive( - timeout=200, pause=10, check=lambda: check_is_alive("gitlab-test") + timeout=300, + pause=10, + check=lambda: check_is_alive("gitlab-test", start_time=start_time), + ) + setup_time = time.perf_counter() - start_time + minutes, seconds = int(setup_time / 60), int(setup_time % 60) + logging.info( + f"GitLab container is now ready after {minutes} minute(s), {seconds} seconds" ) - logging.info("GitLab container is now ready.") token = set_token("gitlab-test", fixture_dir=fixture_dir) pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy