fix: gh-action db 2

This commit is contained in:
Finn Linck Ryan 2025-12-13 22:39:56 +01:00
parent 71b9ddf720
commit e98f259997

View file

@ -60,13 +60,21 @@ jobs:
type=sha,prefix={{branch}}- type=sha,prefix={{branch}}-
type=raw,value=latest,enable={{is_default_branch}} type=raw,value=latest,enable={{is_default_branch}}
- name: Wait for PostgreSQL
run: |
until pg_isready -h localhost -p 5432 -U postgres; do
echo "Waiting for postgres..."
sleep 2
done
- name: Build and publish Docker image - name: Build and publish Docker image
uses: docker/build-push-action@v5 uses: docker/build-push-action@v5
with: with:
context: . context: .
push: true push: true
network: host
build-args: | build-args: |
DB_URL=jdbc:postgresql://postgres:5445/homepage DB_URL=jdbc:postgresql://localhost:5445/homepage
DB_USERNAME=postgres DB_USERNAME=postgres
DB_PASSWORD=postgres DB_PASSWORD=postgres
tags: ${{ steps.meta.outputs.tags }} tags: ${{ steps.meta.outputs.tags }}