Skip to content

Merge pull request #17 from nenadjakic/feature/docker-compose #44

Merge pull request #17 from nenadjakic/feature/docker-compose

Merge pull request #17 from nenadjakic/feature/docker-compose #44

Workflow file for this run

# This is a basic workflow to help you get started with Actions
name: CI
# Controls when the workflow will run
on:
# Triggers the workflow on push or pull request events but only for the "main" branch
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
services:
postgres:
image: postgres
env:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
ports:
- 6432:5432
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
steps:
- name: Set up PostgeSQL database
run: |
PGPASSWORD=postgres psql -U postgres -h 127.0.0.1 -p 6432 -c "CREATE DATABASE \"eav-test\";"
- name: Set up PostgeSQL schemas
run: |
PGPASSWORD=postgres psql -U postgres -h 127.0.0.1 -p 6432 -d eav-test -c "CREATE SCHEMA IF NOT EXISTS public;" -c "CREATE SCHEMA IF NOT EXISTS security;"
- name: Checkout source
uses: actions/checkout@v4
- name: Set up JDK 21
uses: actions/setup-java@v4
with:
java-version: '21'
distribution: 'temurin'
- name: Make gradlew executable
run: chmod +x ./gradlew
- name: Run build with Gradle Wrapper
run: ./gradlew build
- name: Run code coverage verification
run: ./gradlew testCoverage