From 56ab63db01e3e26405286f2aa8842f274e389d48 Mon Sep 17 00:00:00 2001 From: prv-proton Date: Thu, 12 Dec 2024 11:22:31 -0800 Subject: [PATCH 01/13] Fix caching issues in github workflow --- .github/workflows/docker-auto-test.yaml | 15 +++------------ 1 file changed, 3 insertions(+), 12 deletions(-) diff --git a/.github/workflows/docker-auto-test.yaml b/.github/workflows/docker-auto-test.yaml index 1c7976d15..30c21c1dc 100644 --- a/.github/workflows/docker-auto-test.yaml +++ b/.github/workflows/docker-auto-test.yaml @@ -32,18 +32,10 @@ jobs: uses: actions/cache@v3 with: path: ~/.cache/pypoetry - key: ${{ runner.os }}-poetry-${{ hashFiles('**/poetry.lock') }} + key: ${{ runner.os }}-poetry-${{ hashFiles('backend/poetry.lock') }} restore-keys: | ${{ runner.os }}-poetry- - - name: Cache Docker images - uses: actions/cache@v3 - with: - path: /var/lib/docker - key: ${{ runner.os }}-docker-${{ hashFiles('**/Dockerfile') }} - restore-keys: | - ${{ runner.os }}-docker- - - name: Install Poetry run: pip install poetry==1.6.1 @@ -110,7 +102,6 @@ jobs: report_individual_runs: "true" deduplicate_classes_by_file_name: "true" - frontend-tests: runs-on: ubuntu-latest steps: @@ -127,7 +118,7 @@ jobs: uses: actions/cache@v3 with: path: ~/.npm - key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }} + key: ${{ runner.os }}-node-${{ hashFiles('frontend/package-lock.json') }} restore-keys: | ${{ runner.os }}-node- @@ -162,4 +153,4 @@ jobs: check_name: "Frontend Test Results" fail_on: "errors" report_individual_runs: "true" - deduplicate_classes_by_file_name: "true" + deduplicate_classes_by_file_name: "true" \ No newline at end of file From 71c2d5b628911eb3c4cb3c9a0a5c932b805d3320 Mon Sep 17 00:00:00 2001 From: prv-proton Date: Thu, 12 Dec 2024 11:33:57 -0800 Subject: [PATCH 02/13] . --- backend/test.txt | 1 + 1 file changed, 1 insertion(+) create mode 100644 backend/test.txt diff --git a/backend/test.txt b/backend/test.txt new file mode 100644 index 000000000..6a1013938 --- /dev/null +++ b/backend/test.txt @@ -0,0 +1 @@ +testing workflow, remove after testing. \ No newline at end of file From 971335bd93911d90e1364518c2af00a12d91c18d Mon Sep 17 00:00:00 2001 From: prv-proton Date: Thu, 12 Dec 2024 11:48:12 -0800 Subject: [PATCH 03/13] optimize --- .github/workflows/docker-auto-test.yaml | 9 +++++ backend/Dockerfile | 44 +++++++++++-------------- 2 files changed, 28 insertions(+), 25 deletions(-) diff --git a/.github/workflows/docker-auto-test.yaml b/.github/workflows/docker-auto-test.yaml index 30c21c1dc..5b11e92af 100644 --- a/.github/workflows/docker-auto-test.yaml +++ b/.github/workflows/docker-auto-test.yaml @@ -51,6 +51,15 @@ jobs: run: | sed -i 's/: true/: "true"/g; s/: false/: "false"/g' docker-compose.yml + - name: Cache Docker layers + uses: actions/cache@v3 + with: + path: /tmp/.buildx-cache + key: ${{ runner.os }}-docker-${{ github.sha }} + restore-keys: | + ${{ runner.os }}-docker-${{ github.ref_name }} + ${{ runner.os }}-docker- + - name: Build and start services run: | docker-compose build diff --git a/backend/Dockerfile b/backend/Dockerfile index 2f863e90b..749325463 100644 --- a/backend/Dockerfile +++ b/backend/Dockerfile @@ -1,38 +1,31 @@ # Base stage for common setup FROM python:3.11-slim-bullseye as base -RUN apt-get update && apt-get install -y \ - gcc \ - && rm -rf /var/lib/apt/lists/* - -RUN pip install poetry==1.6.1 - -# Configuring poetry -RUN poetry config virtualenvs.create false - -# Copying requirements of a project -COPY pyproject.toml poetry.lock /app/ +# Install build dependencies and Poetry in one step to minimize layers +RUN apt-get update && apt-get install -y --no-install-recommends \ + gcc \ + && pip install --no-cache-dir poetry==1.6.1 \ + && poetry config virtualenvs.create false \ + && apt-get purge -y gcc \ + && rm -rf /var/lib/apt/lists/* + +# Set work directory WORKDIR /app -# Installing requirements -RUN poetry install --only main +# Copy only dependency files first (to leverage caching) +COPY pyproject.toml poetry.lock /app/ -# Removing gcc -RUN apt-get purge -y \ - gcc \ - && rm -rf /var/lib/apt/lists/* +# Install only main dependencies +RUN poetry install --only main --no-root -# Copying the actual application, wait-for-it script, and prestart script +# Copy the rest of the application files COPY . /app/ -# Note: We mount the local directory using docker-compose so ensure these scripts also have execute permissions -# by running the following command on your host machine from the root of this project: -# chmod +x ./backend/wait-for-it.sh ./backend/lcfs/prestart.sh ./backend/lcfs/start.sh ./backend/lcfs/start-reload.sh - -# Make all startup scripts executable +# Make necessary scripts executable RUN chmod +x /app/wait-for-it.sh /app/lcfs/prestart.sh /app/lcfs/start.sh -CMD /bin/bash /app/lcfs/start.sh +# Default startup command +CMD ["/bin/bash", "/app/lcfs/start.sh"] # Production stage FROM base as prod @@ -43,5 +36,6 @@ ENV APP_ENVIRONMENT=prod FROM base as dev # Set the APP_ENVIRONMENT variable to 'development' ENV APP_ENVIRONMENT=dev + # Install additional dependencies for development -RUN poetry install +RUN poetry install --no-root From e73316f699fc3abaa728669ad4ebfbeb953d0b57 Mon Sep 17 00:00:00 2001 From: prv-proton Date: Thu, 12 Dec 2024 11:54:50 -0800 Subject: [PATCH 04/13] update --- backend/test.txt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/backend/test.txt b/backend/test.txt index 6a1013938..742cf3868 100644 --- a/backend/test.txt +++ b/backend/test.txt @@ -1 +1,2 @@ -testing workflow, remove after testing. \ No newline at end of file +testing workflow, remove after testing. +update to app files. \ No newline at end of file From 929e2fc33c30cd92ea26e65209e3eeddfe8024aa Mon Sep 17 00:00:00 2001 From: prv-proton Date: Thu, 12 Dec 2024 11:59:59 -0800 Subject: [PATCH 05/13] Revert "optimize" This reverts commit 971335bd93911d90e1364518c2af00a12d91c18d. --- .github/workflows/docker-auto-test.yaml | 9 ----- backend/Dockerfile | 44 ++++++++++++++----------- 2 files changed, 25 insertions(+), 28 deletions(-) diff --git a/.github/workflows/docker-auto-test.yaml b/.github/workflows/docker-auto-test.yaml index 5b11e92af..30c21c1dc 100644 --- a/.github/workflows/docker-auto-test.yaml +++ b/.github/workflows/docker-auto-test.yaml @@ -51,15 +51,6 @@ jobs: run: | sed -i 's/: true/: "true"/g; s/: false/: "false"/g' docker-compose.yml - - name: Cache Docker layers - uses: actions/cache@v3 - with: - path: /tmp/.buildx-cache - key: ${{ runner.os }}-docker-${{ github.sha }} - restore-keys: | - ${{ runner.os }}-docker-${{ github.ref_name }} - ${{ runner.os }}-docker- - - name: Build and start services run: | docker-compose build diff --git a/backend/Dockerfile b/backend/Dockerfile index 749325463..2f863e90b 100644 --- a/backend/Dockerfile +++ b/backend/Dockerfile @@ -1,31 +1,38 @@ # Base stage for common setup FROM python:3.11-slim-bullseye as base -# Install build dependencies and Poetry in one step to minimize layers -RUN apt-get update && apt-get install -y --no-install-recommends \ - gcc \ - && pip install --no-cache-dir poetry==1.6.1 \ - && poetry config virtualenvs.create false \ - && apt-get purge -y gcc \ - && rm -rf /var/lib/apt/lists/* - -# Set work directory -WORKDIR /app +RUN apt-get update && apt-get install -y \ + gcc \ + && rm -rf /var/lib/apt/lists/* + +RUN pip install poetry==1.6.1 -# Copy only dependency files first (to leverage caching) +# Configuring poetry +RUN poetry config virtualenvs.create false + +# Copying requirements of a project COPY pyproject.toml poetry.lock /app/ +WORKDIR /app -# Install only main dependencies -RUN poetry install --only main --no-root +# Installing requirements +RUN poetry install --only main -# Copy the rest of the application files +# Removing gcc +RUN apt-get purge -y \ + gcc \ + && rm -rf /var/lib/apt/lists/* + +# Copying the actual application, wait-for-it script, and prestart script COPY . /app/ -# Make necessary scripts executable +# Note: We mount the local directory using docker-compose so ensure these scripts also have execute permissions +# by running the following command on your host machine from the root of this project: +# chmod +x ./backend/wait-for-it.sh ./backend/lcfs/prestart.sh ./backend/lcfs/start.sh ./backend/lcfs/start-reload.sh + +# Make all startup scripts executable RUN chmod +x /app/wait-for-it.sh /app/lcfs/prestart.sh /app/lcfs/start.sh -# Default startup command -CMD ["/bin/bash", "/app/lcfs/start.sh"] +CMD /bin/bash /app/lcfs/start.sh # Production stage FROM base as prod @@ -36,6 +43,5 @@ ENV APP_ENVIRONMENT=prod FROM base as dev # Set the APP_ENVIRONMENT variable to 'development' ENV APP_ENVIRONMENT=dev - # Install additional dependencies for development -RUN poetry install --no-root +RUN poetry install From 8d17b43df67e2289cbb7d932ecddb2a2182dec9b Mon Sep 17 00:00:00 2001 From: prv-proton Date: Thu, 12 Dec 2024 12:12:34 -0800 Subject: [PATCH 06/13] parallelize tests --- .github/workflows/docker-auto-test.yaml | 2 +- backend/poetry.lock | 46 +++++++++++++++++++++---- backend/pyproject.toml | 1 + 3 files changed, 42 insertions(+), 7 deletions(-) diff --git a/.github/workflows/docker-auto-test.yaml b/.github/workflows/docker-auto-test.yaml index 30c21c1dc..0c47293b0 100644 --- a/.github/workflows/docker-auto-test.yaml +++ b/.github/workflows/docker-auto-test.yaml @@ -61,7 +61,7 @@ jobs: continue-on-error: true run: | cd backend - poetry run pytest --junitxml=pytest-results.xml + poetry run pytest -n auto --junitxml=pytest-results.xml env: LCFS_DB_HOST: localhost LCFS_DB_PORT: 5432 diff --git a/backend/poetry.lock b/backend/poetry.lock index 30bf2f4bf..146fc519d 100644 --- a/backend/poetry.lock +++ b/backend/poetry.lock @@ -1,4 +1,4 @@ -# This file is automatically @generated by Poetry 1.8.3 and should not be changed by hand. +# This file is automatically @generated by Poetry 1.5.1 and should not be changed by hand. [[package]] name = "aio-pika" @@ -306,8 +306,8 @@ files = [ jmespath = ">=0.7.1,<2.0.0" python-dateutil = ">=2.1,<3.0.0" urllib3 = [ - {version = ">=1.25.4,<2.2.0 || >2.2.0,<3", markers = "python_version >= \"3.10\""}, {version = ">=1.25.4,<1.27", markers = "python_version < \"3.10\""}, + {version = ">=1.25.4,<2.2.0 || >2.2.0,<3", markers = "python_version >= \"3.10\""}, ] [package.extras] @@ -835,6 +835,20 @@ files = [ [package.extras] test = ["pytest (>=6)"] +[[package]] +name = "execnet" +version = "2.1.1" +description = "execnet: rapid multi-Python deployment" +optional = false +python-versions = ">=3.8" +files = [ + {file = "execnet-2.1.1-py3-none-any.whl", hash = "sha256:26dee51f1b80cebd6d0ca8e74dd8745419761d3bef34163928cbebbdc4749fdc"}, + {file = "execnet-2.1.1.tar.gz", hash = "sha256:5189b52c6121c24feae288166ab41b32549c7e2348652736540b9e6e7d4e72e3"}, +] + +[package.extras] +testing = ["hatch", "pre-commit", "pytest", "tox"] + [[package]] name = "fakeredis" version = "2.26.1" @@ -2113,9 +2127,9 @@ files = [ [package.dependencies] numpy = [ - {version = ">=1.26.0", markers = "python_version >= \"3.12\""}, {version = ">=1.22.4", markers = "python_version < \"3.11\""}, {version = ">=1.23.2", markers = "python_version == \"3.11\""}, + {version = ">=1.26.0", markers = "python_version >= \"3.12\""}, ] python-dateutil = ">=2.8.2" pytz = ">=2020.1" @@ -2504,8 +2518,8 @@ annotated-types = ">=0.6.0" email-validator = {version = ">=2.0.0", optional = true, markers = "extra == \"email\""} pydantic-core = "2.23.4" typing-extensions = [ - {version = ">=4.12.2", markers = "python_version >= \"3.13\""}, {version = ">=4.6.1", markers = "python_version < \"3.13\""}, + {version = ">=4.12.2", markers = "python_version >= \"3.13\""}, ] [package.extras] @@ -2749,6 +2763,26 @@ pytest = ">=7.3.1" [package.extras] test = ["coverage (>=7.2.7)", "pytest-mock (>=3.10)"] +[[package]] +name = "pytest-xdist" +version = "3.6.1" +description = "pytest xdist plugin for distributed testing, most importantly across multiple CPUs" +optional = false +python-versions = ">=3.8" +files = [ + {file = "pytest_xdist-3.6.1-py3-none-any.whl", hash = "sha256:9ed4adfb68a016610848639bb7e02c9352d5d9f03d04809919e2dafc3be4cca7"}, + {file = "pytest_xdist-3.6.1.tar.gz", hash = "sha256:ead156a4db231eec769737f57668ef58a2084a34b2e55c4a8fa20d861107300d"}, +] + +[package.dependencies] +execnet = ">=2.1" +pytest = ">=7.0.0" + +[package.extras] +psutil = ["psutil (>=3.0)"] +setproctitle = ["setproctitle"] +testing = ["filelock"] + [[package]] name = "python-dateutil" version = "2.9.0.post0" @@ -3109,7 +3143,7 @@ files = [ ] [package.dependencies] -greenlet = {version = "!=0.4.17", optional = true, markers = "python_version < \"3.13\" and (platform_machine == \"aarch64\" or platform_machine == \"ppc64le\" or platform_machine == \"x86_64\" or platform_machine == \"amd64\" or platform_machine == \"AMD64\" or platform_machine == \"win32\" or platform_machine == \"WIN32\") or extra == \"asyncio\""} +greenlet = {version = "!=0.4.17", optional = true, markers = "python_version < \"3.13\" and (platform_machine == \"win32\" or platform_machine == \"WIN32\" or platform_machine == \"AMD64\" or platform_machine == \"amd64\" or platform_machine == \"x86_64\" or platform_machine == \"ppc64le\" or platform_machine == \"aarch64\") or extra == \"asyncio\""} typing-extensions = ">=4.6.0" [package.extras] @@ -3784,4 +3818,4 @@ propcache = ">=0.2.0" [metadata] lock-version = "2.0" python-versions = "^3.9" -content-hash = "1898dc5b68facf49cb53d1fe98daecb39c1dc39b184d17c31d8d23a48cfce2c0" +content-hash = "55d9cb15f5685f6da727dfa156a16ac4d8085c6c6f98bec321f9e8b311bb162f" diff --git a/backend/pyproject.toml b/backend/pyproject.toml index e40217ccb..8d64b46a2 100644 --- a/backend/pyproject.toml +++ b/backend/pyproject.toml @@ -46,6 +46,7 @@ python-multipart = "^0.0.18" aio-pika = "^9.4.3" jinja2 = "^3.1.4" requests = "^2.32.3" +pytest-xdist = "^3.6.1" [tool.poetry.dev-dependencies] pytest = "^8.3.3" From 8195a590972603c8b3055b27c47df66bc5997997 Mon Sep 17 00:00:00 2001 From: prv-proton Date: Thu, 12 Dec 2024 12:18:37 -0800 Subject: [PATCH 07/13] Revert "parallelize tests" This reverts commit 8d17b43df67e2289cbb7d932ecddb2a2182dec9b. --- .github/workflows/docker-auto-test.yaml | 2 +- backend/poetry.lock | 46 ++++--------------------- backend/pyproject.toml | 1 - 3 files changed, 7 insertions(+), 42 deletions(-) diff --git a/.github/workflows/docker-auto-test.yaml b/.github/workflows/docker-auto-test.yaml index 0c47293b0..30c21c1dc 100644 --- a/.github/workflows/docker-auto-test.yaml +++ b/.github/workflows/docker-auto-test.yaml @@ -61,7 +61,7 @@ jobs: continue-on-error: true run: | cd backend - poetry run pytest -n auto --junitxml=pytest-results.xml + poetry run pytest --junitxml=pytest-results.xml env: LCFS_DB_HOST: localhost LCFS_DB_PORT: 5432 diff --git a/backend/poetry.lock b/backend/poetry.lock index 146fc519d..30bf2f4bf 100644 --- a/backend/poetry.lock +++ b/backend/poetry.lock @@ -1,4 +1,4 @@ -# This file is automatically @generated by Poetry 1.5.1 and should not be changed by hand. +# This file is automatically @generated by Poetry 1.8.3 and should not be changed by hand. [[package]] name = "aio-pika" @@ -306,8 +306,8 @@ files = [ jmespath = ">=0.7.1,<2.0.0" python-dateutil = ">=2.1,<3.0.0" urllib3 = [ - {version = ">=1.25.4,<1.27", markers = "python_version < \"3.10\""}, {version = ">=1.25.4,<2.2.0 || >2.2.0,<3", markers = "python_version >= \"3.10\""}, + {version = ">=1.25.4,<1.27", markers = "python_version < \"3.10\""}, ] [package.extras] @@ -835,20 +835,6 @@ files = [ [package.extras] test = ["pytest (>=6)"] -[[package]] -name = "execnet" -version = "2.1.1" -description = "execnet: rapid multi-Python deployment" -optional = false -python-versions = ">=3.8" -files = [ - {file = "execnet-2.1.1-py3-none-any.whl", hash = "sha256:26dee51f1b80cebd6d0ca8e74dd8745419761d3bef34163928cbebbdc4749fdc"}, - {file = "execnet-2.1.1.tar.gz", hash = "sha256:5189b52c6121c24feae288166ab41b32549c7e2348652736540b9e6e7d4e72e3"}, -] - -[package.extras] -testing = ["hatch", "pre-commit", "pytest", "tox"] - [[package]] name = "fakeredis" version = "2.26.1" @@ -2127,9 +2113,9 @@ files = [ [package.dependencies] numpy = [ + {version = ">=1.26.0", markers = "python_version >= \"3.12\""}, {version = ">=1.22.4", markers = "python_version < \"3.11\""}, {version = ">=1.23.2", markers = "python_version == \"3.11\""}, - {version = ">=1.26.0", markers = "python_version >= \"3.12\""}, ] python-dateutil = ">=2.8.2" pytz = ">=2020.1" @@ -2518,8 +2504,8 @@ annotated-types = ">=0.6.0" email-validator = {version = ">=2.0.0", optional = true, markers = "extra == \"email\""} pydantic-core = "2.23.4" typing-extensions = [ - {version = ">=4.6.1", markers = "python_version < \"3.13\""}, {version = ">=4.12.2", markers = "python_version >= \"3.13\""}, + {version = ">=4.6.1", markers = "python_version < \"3.13\""}, ] [package.extras] @@ -2763,26 +2749,6 @@ pytest = ">=7.3.1" [package.extras] test = ["coverage (>=7.2.7)", "pytest-mock (>=3.10)"] -[[package]] -name = "pytest-xdist" -version = "3.6.1" -description = "pytest xdist plugin for distributed testing, most importantly across multiple CPUs" -optional = false -python-versions = ">=3.8" -files = [ - {file = "pytest_xdist-3.6.1-py3-none-any.whl", hash = "sha256:9ed4adfb68a016610848639bb7e02c9352d5d9f03d04809919e2dafc3be4cca7"}, - {file = "pytest_xdist-3.6.1.tar.gz", hash = "sha256:ead156a4db231eec769737f57668ef58a2084a34b2e55c4a8fa20d861107300d"}, -] - -[package.dependencies] -execnet = ">=2.1" -pytest = ">=7.0.0" - -[package.extras] -psutil = ["psutil (>=3.0)"] -setproctitle = ["setproctitle"] -testing = ["filelock"] - [[package]] name = "python-dateutil" version = "2.9.0.post0" @@ -3143,7 +3109,7 @@ files = [ ] [package.dependencies] -greenlet = {version = "!=0.4.17", optional = true, markers = "python_version < \"3.13\" and (platform_machine == \"win32\" or platform_machine == \"WIN32\" or platform_machine == \"AMD64\" or platform_machine == \"amd64\" or platform_machine == \"x86_64\" or platform_machine == \"ppc64le\" or platform_machine == \"aarch64\") or extra == \"asyncio\""} +greenlet = {version = "!=0.4.17", optional = true, markers = "python_version < \"3.13\" and (platform_machine == \"aarch64\" or platform_machine == \"ppc64le\" or platform_machine == \"x86_64\" or platform_machine == \"amd64\" or platform_machine == \"AMD64\" or platform_machine == \"win32\" or platform_machine == \"WIN32\") or extra == \"asyncio\""} typing-extensions = ">=4.6.0" [package.extras] @@ -3818,4 +3784,4 @@ propcache = ">=0.2.0" [metadata] lock-version = "2.0" python-versions = "^3.9" -content-hash = "55d9cb15f5685f6da727dfa156a16ac4d8085c6c6f98bec321f9e8b311bb162f" +content-hash = "1898dc5b68facf49cb53d1fe98daecb39c1dc39b184d17c31d8d23a48cfce2c0" diff --git a/backend/pyproject.toml b/backend/pyproject.toml index 8d64b46a2..e40217ccb 100644 --- a/backend/pyproject.toml +++ b/backend/pyproject.toml @@ -46,7 +46,6 @@ python-multipart = "^0.0.18" aio-pika = "^9.4.3" jinja2 = "^3.1.4" requests = "^2.32.3" -pytest-xdist = "^3.6.1" [tool.poetry.dev-dependencies] pytest = "^8.3.3" From ad157c144b8146068989caeb3c624114770749cc Mon Sep 17 00:00:00 2001 From: prv-proton Date: Thu, 12 Dec 2024 13:56:26 -0800 Subject: [PATCH 08/13] finalize --- backend/test.txt | 2 -- 1 file changed, 2 deletions(-) delete mode 100644 backend/test.txt diff --git a/backend/test.txt b/backend/test.txt deleted file mode 100644 index 742cf3868..000000000 --- a/backend/test.txt +++ /dev/null @@ -1,2 +0,0 @@ -testing workflow, remove after testing. -update to app files. \ No newline at end of file From 1f21cc6589f4184eb954d958a75afbe0eab48124 Mon Sep 17 00:00:00 2001 From: prv-proton Date: Thu, 12 Dec 2024 14:01:59 -0800 Subject: [PATCH 09/13] update --- .github/workflows/docker-auto-test.yaml | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/.github/workflows/docker-auto-test.yaml b/.github/workflows/docker-auto-test.yaml index 30c21c1dc..e690e70ff 100644 --- a/.github/workflows/docker-auto-test.yaml +++ b/.github/workflows/docker-auto-test.yaml @@ -47,14 +47,18 @@ jobs: poetry install pip install pytest-github-actions-annotate-failures typing_extensions - - name: Fix docker-compose.yml + - name: Modify docker-compose.yml run: | - sed -i 's/: true/: "true"/g; s/: false/: "false"/g' docker-compose.yml + sed -i '/minio:/,/depends_on:/d' docker-compose.yml + sed -i '/create_bucket:/,/depends_on:/d' docker-compose.yml + sed -i '/frontend:/,/networks:/d' docker-compose.yml + sed -i 's/create_bucket,//g' + sed -i 's/frontend,//g' - name: Build and start services run: | docker-compose build - docker-compose up -d + docker-compose up -d db redis rabbitmq backend - name: Run backend tests id: backend_tests From 33a3c0d724bcda86f243ed689aeaaede84091db8 Mon Sep 17 00:00:00 2001 From: prv-proton Date: Thu, 12 Dec 2024 14:05:42 -0800 Subject: [PATCH 10/13] . --- .github/workflows/docker-auto-test.yaml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/docker-auto-test.yaml b/.github/workflows/docker-auto-test.yaml index e690e70ff..a0b650155 100644 --- a/.github/workflows/docker-auto-test.yaml +++ b/.github/workflows/docker-auto-test.yaml @@ -49,6 +49,7 @@ jobs: - name: Modify docker-compose.yml run: | + sed -i 's/: true/: "true"/g; s/: false/: "false"/g' docker-compose.yml sed -i '/minio:/,/depends_on:/d' docker-compose.yml sed -i '/create_bucket:/,/depends_on:/d' docker-compose.yml sed -i '/frontend:/,/networks:/d' docker-compose.yml @@ -58,7 +59,7 @@ jobs: - name: Build and start services run: | docker-compose build - docker-compose up -d db redis rabbitmq backend + docker-compose up -d - name: Run backend tests id: backend_tests From 882a3819c461890c8b9c48b0f9d9f9e5d438e300 Mon Sep 17 00:00:00 2001 From: prv-proton Date: Thu, 12 Dec 2024 14:07:31 -0800 Subject: [PATCH 11/13] . --- .github/workflows/docker-auto-test.yaml | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) diff --git a/.github/workflows/docker-auto-test.yaml b/.github/workflows/docker-auto-test.yaml index a0b650155..837d2d171 100644 --- a/.github/workflows/docker-auto-test.yaml +++ b/.github/workflows/docker-auto-test.yaml @@ -18,11 +18,6 @@ jobs: with: python-version: "3.10.13" - - name: Set up Node.js - uses: actions/setup-node@v3 - with: - node-version: "20" - - name: Install Docker Compose run: | sudo apt-get update @@ -47,14 +42,9 @@ jobs: poetry install pip install pytest-github-actions-annotate-failures typing_extensions - - name: Modify docker-compose.yml + - name: Fix docker-compose.yml run: | sed -i 's/: true/: "true"/g; s/: false/: "false"/g' docker-compose.yml - sed -i '/minio:/,/depends_on:/d' docker-compose.yml - sed -i '/create_bucket:/,/depends_on:/d' docker-compose.yml - sed -i '/frontend:/,/networks:/d' docker-compose.yml - sed -i 's/create_bucket,//g' - sed -i 's/frontend,//g' - name: Build and start services run: | From b488ee95772c47fb84ecaa06c648681b07c9960d Mon Sep 17 00:00:00 2001 From: prv-proton Date: Thu, 12 Dec 2024 14:28:11 -0800 Subject: [PATCH 12/13] . --- .github/workflows/docker-auto-test.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/docker-auto-test.yaml b/.github/workflows/docker-auto-test.yaml index 837d2d171..fe886f335 100644 --- a/.github/workflows/docker-auto-test.yaml +++ b/.github/workflows/docker-auto-test.yaml @@ -49,7 +49,7 @@ jobs: - name: Build and start services run: | docker-compose build - docker-compose up -d + docker-compose up -d db redis rabbitmq backend - name: Run backend tests id: backend_tests From c2864ecea19290d7a2afab618aeb5ff9fff69f24 Mon Sep 17 00:00:00 2001 From: prv-proton Date: Thu, 12 Dec 2024 14:32:39 -0800 Subject: [PATCH 13/13] . --- .github/workflows/docker-auto-test.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/docker-auto-test.yaml b/.github/workflows/docker-auto-test.yaml index fe886f335..837d2d171 100644 --- a/.github/workflows/docker-auto-test.yaml +++ b/.github/workflows/docker-auto-test.yaml @@ -49,7 +49,7 @@ jobs: - name: Build and start services run: | docker-compose build - docker-compose up -d db redis rabbitmq backend + docker-compose up -d - name: Run backend tests id: backend_tests