chore: update postgres service configuration in CI workflow to use dynamic port mapping

This commit is contained in:
ramvignesh-b
2026-05-04 23:30:31 +05:30
parent 2c9ca8356c
commit d3f9182725
+5 -2
View File
@@ -11,8 +11,6 @@ env:
DB_NAME: piku_test_db DB_NAME: piku_test_db
DB_USER: test DB_USER: test
DB_PASSWORD: password123 DB_PASSWORD: password123
DB_HOST: postgres
DB_PORT: 5432
jobs: jobs:
setup-environment: setup-environment:
@@ -75,7 +73,12 @@ jobs:
POSTGRES_DB: ${{ env.DB_NAME }} POSTGRES_DB: ${{ env.DB_NAME }}
POSTGRES_USER: ${{ env.DB_USER }} POSTGRES_USER: ${{ env.DB_USER }}
POSTGRES_PASSWORD: ${{ env.DB_PASSWORD }} POSTGRES_PASSWORD: ${{ env.DB_PASSWORD }}
ports:
- 5432
options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5 options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5
env:
DB_HOST: 127.0.0.1
DB_PORT: ${{ job.services.postgres.ports['5432'] }}
defaults: defaults:
run: run:
working-directory: ./backend working-directory: ./backend