From f2edc36e1110f6a42946d25d6be638a82a9ad978 Mon Sep 17 00:00:00 2001 From: Stanislav Trailov Date: Mon, 20 Apr 2026 10:04:12 +0300 Subject: [PATCH] Add verify with Postgre (#3005) * Add verify with Postgre Signed-off-by: strailov * make them only on trigger manually Signed-off-by: strailov --------- Signed-off-by: strailov --- .github/workflows/reusable_workflow_verify.yaml | 13 +++++++++++++ .../workflows/verify-hibernate-postgresql.yaml | 15 +++++++++++++++ .github/workflows/verify-postgresql.yaml | 15 +++++++++++++++ 3 files changed, 43 insertions(+) create mode 100644 .github/workflows/verify-hibernate-postgresql.yaml create mode 100644 .github/workflows/verify-postgresql.yaml diff --git a/.github/workflows/reusable_workflow_verify.yaml b/.github/workflows/reusable_workflow_verify.yaml index 3ff4f7523..3959a5746 100644 --- a/.github/workflows/reusable_workflow_verify.yaml +++ b/.github/workflows/reusable_workflow_verify.yaml @@ -33,6 +33,19 @@ jobs: ports: - 15672:15672 - 5672:5672 + postgresql: + image: postgres:16.5 + env: + POSTGRES_DB: hawkbit + POSTGRES_USER: postgres + POSTGRES_PASSWORD: admin + options: >- + --health-cmd "pg_isready -d hawkbit -U postgres" + --health-interval 20s + --health-timeout 5s + --health-retries 10 + ports: + - 5432:5432 steps: - name: Parameters diff --git a/.github/workflows/verify-hibernate-postgresql.yaml b/.github/workflows/verify-hibernate-postgresql.yaml new file mode 100644 index 000000000..96138412f --- /dev/null +++ b/.github/workflows/verify-hibernate-postgresql.yaml @@ -0,0 +1,15 @@ +name: Verify (Hibernate + PostgreSQL) + +on: + workflow_dispatch: + +permissions: + contents: read + +jobs: + verify-hibernate-postgresql: + uses: ./.github/workflows/reusable_workflow_verify.yaml + with: + repository: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name || github.repository }} + ref: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.ref || github.ref }} + maven_properties: '-Djpa.vendor=hibernate -Dlogging.level.org.hibernate.collection.spi.AbstractPersistentCollection=ERROR -Dspring.jpa.database=POSTGRESQL -Dspring.datasource.url=jdbc:postgresql://localhost:5432/hawkbit -Dspring.datasource.username=postgres -Dspring.datasource.password=admin' diff --git a/.github/workflows/verify-postgresql.yaml b/.github/workflows/verify-postgresql.yaml new file mode 100644 index 000000000..85d8e73e8 --- /dev/null +++ b/.github/workflows/verify-postgresql.yaml @@ -0,0 +1,15 @@ +name: Verify (PostgreSQL) + +on: + workflow_dispatch: + +permissions: + contents: read + +jobs: + verify-postgresql: + uses: ./.github/workflows/reusable_workflow_verify.yaml + with: + repository: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name || github.repository }} + ref: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.ref || github.ref }} + maven_properties: '-Dspring.jpa.database=POSTGRESQL -Dspring.datasource.url=jdbc:postgresql://localhost:5432/hawkbit -Dspring.datasource.username=postgres -Dspring.datasource.password=admin'