Skip to content

ci: add redis service #277

ci: add redis service

ci: add redis service #277

Workflow file for this run

#

Check failure on line 1 in .github/workflows/ci.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/ci.yml

Invalid workflow file

No steps defined in `steps` and no workflow called in `uses` for the following jobs: redis-integration-test
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
# This workflow will build a Java project with Maven
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-maven
name: Continuous Integration
on:
push:
branches: [ dev ]
paths:
- '.github/workflows/ci.yml'
- '**/pom.xml'
- '**/src/main/**'
- '**/src/test/**'
- '!*.md'
- '!docs/**'
pull_request:
branches: [ dev ]
paths:
- '.github/workflows/ci.yml'
- '**/pom.xml'
- '**/src/main/**'
- '**/src/test/**'
- '!*.md'
- '!docs/**'
repository_dispatch:
types: [rerun-ci]
concurrency:
group: ${{ github.event_name }}-${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
# Label of the container job
redis-integration-test:
runs-on: ubuntu-latest
services:
# Label used to access the service container
redis:
# Docker Hub image
image: redis:alpine
# Set health checks to wait until redis has started
options: >-
--health-cmd "redis-cli ping"
--health-interval 10s
--health-timeout 5s
--health-retries 5
ports:
# Maps port 6379 on service container to the host
- 6379:6379
unix:
name: JDK ${{ matrix.java.version }} - on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
timeout-minutes: 60
strategy:
matrix:
os: [ macos-latest ]
java:
- {
version: 11
}
- {
version: 17
}
steps:
- uses: actions/checkout@v3
- name: Build with Maven
run: echo y | mvn clean install -Dskip.gpg=true -Dspotless.apply.skip=true -Dmaven.javadoc.skip=true
test-coverage:
if: github.repository == 'opengoofy/crane4j'
name: Test coverage report
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Cache Maven Repos
uses: actions/cache@v3
with:
path: ~/.m2/repository
key: crane4j-maven-third-party-${{ hashFiles('**/pom.xml') }}
restore-keys: |
crane4j-maven-third-party-
- uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: 8
- name: Test with Maven
run: echo y | mvn -T1C clean install -Dskip.gpg=true -Dspotless.apply.skip=true -Dskip.jacoco.plugin=false
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v3