From ebd7c9faef4a744e6593fb62807dfb63acba990f Mon Sep 17 00:00:00 2001 From: eric-intuitem <71850047+eric-intuitem@users.noreply.github.com> Date: Sun, 22 Dec 2024 17:45:11 +0100 Subject: [PATCH] Update startup-tests.yml tentative fix for broken startup test --- .github/workflows/startup-tests.yml | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/.github/workflows/startup-tests.yml b/.github/workflows/startup-tests.yml index a102afced..4aa13ca12 100644 --- a/.github/workflows/startup-tests.yml +++ b/.github/workflows/startup-tests.yml @@ -122,7 +122,10 @@ jobs: working-directory: ${{ env.frontend-directory }} run: pnpm exec playwright install - name: Build the Docker app - run: docker compose -f docker-compose-build.yml up -d + run: | + rm -rf db + mkdir db + docker compose -f docker-compose-build.yml up -d - name: Create backend environment variables file working-directory: ${{ env.backend-directory }} run: | @@ -130,7 +133,7 @@ jobs: export $(grep -v '^#' .env | xargs) - name: Config the Docker app run: | - sleep 180 # give the migrations time to finish (included in the up on the previous step) + sleep 120 # give the migrations time to finish (included in the up on the previous step) docker compose -f docker-compose-build.yml exec backend /bin/bash -c "DJANGO_SUPERUSER_EMAIL=admin@tests.com DJANGO_SUPERUSER_PASSWORD=1234 poetry run python manage.py createsuperuser --noinput && exit 0" - name: Run tests working-directory: ${{ env.frontend-directory }} @@ -261,7 +264,7 @@ jobs: export $(grep -v '^#' .env | xargs) - name: Config the Docker app run: | - sleep 180 # give the migrations time to finish (included in the up on the previous step) + sleep 120 # give the migrations time to finish (included in the up on the previous step) docker compose -f enterprise/docker-compose-build.yml exec backend /bin/bash -c "DJANGO_SUPERUSER_EMAIL=admin@tests.com DJANGO_SUPERUSER_PASSWORD=1234 poetry run python manage.py createsuperuser --noinput --settings=${{ env.enterprise-backend-settings-module }} && exit 0" - name: Run tests working-directory: ${{ env.frontend-directory }}