From 6b9c04820b100f6043ab084a1d7b376140d83c38 Mon Sep 17 00:00:00 2001 From: Francisco Solla Date: Mon, 17 Aug 2026 03:56:29 -0300 Subject: [PATCH] =?UTF-8?q?fix(ci=20OPS50):=20vitest/playwright=20recarreg?= =?UTF-8?q?am=20.env.test=20por=20cima=20do=20env=20do=20job=20=E2=80=94?= =?UTF-8?q?=20gravar=20DATABASE=5FURL=20do=20servi=C3=A7o=20em=20.env.test?= =?UTF-8?q?.local=20(camada=20que=20vence)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .forgejo/workflows/ci-pr.yml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/.forgejo/workflows/ci-pr.yml b/.forgejo/workflows/ci-pr.yml index 85679ae4..ab6e72ac 100644 --- a/.forgejo/workflows/ci-pr.yml +++ b/.forgejo/workflows/ci-pr.yml @@ -208,6 +208,10 @@ jobs: set -euo pipefail DB_HOST=$(awk '$2 == "00000000" {a=$3; print strtonum("0x" substr(a,7,2)) "." strtonum("0x" substr(a,5,2)) "." strtonum("0x" substr(a,3,2)) "." strtonum("0x" substr(a,1,2)); exit}' /proc/net/route) echo "DATABASE_URL=postgresql://teqo:teqo@${DB_HOST}:5433/teqo_test" >> "$GITHUB_ENV" + # vitest/playwright re-load .env.test over the process env, so the + # service URL must win through the .env.test.local layer (same + # mechanism `pnpm worktree next` uses). OPS50. + echo "DATABASE_URL=postgresql://teqo:teqo@${DB_HOST}:5433/teqo_test" > .env.test.local - run: pnpm migrate - run: pnpm db:seed:minimal @@ -325,6 +329,10 @@ jobs: DB_HOST=$(awk '$2 == "00000000" {a=$3; print strtonum("0x" substr(a,7,2)) "." strtonum("0x" substr(a,5,2)) "." strtonum("0x" substr(a,3,2)) "." strtonum("0x" substr(a,1,2)); exit}' /proc/net/route) DB_PORT=${{ matrix.shard == 1 && '5435' || '5436' }} echo "DATABASE_URL=postgresql://teqo:teqo@${DB_HOST}:${DB_PORT}/teqo_test" >> "$GITHUB_ENV" + # vitest/playwright re-load .env.test over the process env, so the + # service URL must win through the .env.test.local layer (same + # mechanism `pnpm worktree next` uses). OPS50. + echo "DATABASE_URL=postgresql://teqo:teqo@${DB_HOST}:${DB_PORT}/teqo_test" > .env.test.local - run: pnpm migrate - run: pnpm db:seed:minimal - name: Build for e2e