chore: upgrade jvm to 21 on GHA test #59
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Test | |
on: | |
push: | |
branches: | |
- '**' | |
jobs: | |
build-and-test: | |
name: "Migrate, Build & Test" | |
runs-on: ubuntu-latest | |
env: | |
ABLY_API_KEY: ${{ secrets.ABLY_PUBLISH_ONLY_TEST_KEY }} | |
JWT_SECRET: key-for-tests | |
LOG_LEVEL: info | |
PORT: 8080 | |
STABLE_DB_PASSWORD: db.password | |
STABLE_DB_USER: postgres | |
STABLE_DB_MAX_CONNECTIONS: 10 | |
STABLE_JDBC_URL: jdbc:postgresql://localhost:5432/postgres | |
PGSSLROOTCERT: /etc/ssl/certs/ca-certificates.crt | |
services: | |
postgres: | |
image: postgres:16-alpine | |
env: | |
POSTGRES_PASSWORD: db.password | |
options: >- | |
--health-cmd "pg_isready -U postgres" | |
--health-interval 10s | |
--health-timeout 5s | |
--health-retries 5 | |
ports: | |
- 5432:5432 | |
volumes: | |
- postgres-data:/var/lib/postgresql/data | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Set up JDK 21 (Corretto) | |
uses: actions/setup-java@v4 | |
with: | |
java-version: '21' | |
distribution: 'corretto' | |
- name: Install | |
run: ./gradlew --quiet dependencies | |
- name: Migrate | |
run: ./gradlew migrate | |
- name: Test | |
run: ./gradlew test | |