CI #193
Workflow file for this run
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: CI | |
on: [push, pull_request] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
# change in sync with gradle.properties | |
scala: [2.12.19, 2.13.14] | |
# see build.gradle copy template tasks | |
db: [MySQL, H2] | |
# Service containers to run with `container-job` | |
services: | |
mysql: | |
image: mysql:8.0.31 | |
ports: | |
- 3307:3306 | |
env: | |
# make sure to use something more secure in production | |
MYSQL_ROOT_PASSWORD: 1234 | |
MYSQL_DATABASE: warp_core | |
influxdb: | |
image: influxdb:1.5.2 | |
ports: | |
- 8086:8086 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set up JDK | |
uses: actions/setup-java@v3 | |
with: | |
distribution: 'zulu' | |
java-version: '11' | |
- name: Compile | |
run: ./gradlew clean compileTestScala -PscalaVersion=${{ matrix.scala }} | |
- name: Cache Gradle packages | |
uses: actions/cache@v3 | |
with: | |
path: ~/.gradle/caches | |
key: ${{ runner.os }}-gradle-${{ matrix.scala }}-${{ hashFiles('**/*.gradle') }} | |
restore-keys: ${{ runner.os }}-gradle-${{ matrix.scala }} | |
- name: Build with Gradle | |
run: ./gradlew copy${{ matrix.db }}ConfigTemplate :warp-core:checkScoverage aggregateScoverage checkScalafix publishToMavenLocal -PscalaVersion=${{ matrix.scala }} -PshowTestStandardStreams=true --stacktrace |