Configure Renovate #84
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: | |
pull_request: | |
push: | |
branches: | |
- main | |
tags: | |
- v* | |
release: | |
types: | |
- published | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
fetch-depth: 0 | |
- uses: actions/setup-java@v1 | |
with: | |
java-version: 11 | |
- name: Check | |
run: ./gradlew check | |
- name: Upload test reports | |
if: ${{ failure() }} | |
uses: actions/upload-artifact@v2 | |
with: | |
name: reports-build | |
path: '**/build/reports/' | |
- name: Upload analysis to sonarcloud | |
if: "${{ env.SONAR_TOKEN != '' }}" | |
env: | |
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} | |
GITHUB_TOKEN: ${{ github.token }} | |
run: ./gradlew sonarqube -Dsonar.projectKey=xenit-eu_nuntio -Dsonar.organization=xenit-eu -Dsonar.host.url=https://sonarcloud.io | |
publish: | |
needs: | |
- build | |
if: ${{ startsWith(github.ref, 'refs/tags/') || github.ref == 'refs/heads/main' }} | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
fetch-depth: 0 | |
- uses: actions/setup-java@v1 | |
with: | |
java-version: 11 | |
- name: Publish docker images | |
env: | |
DOCKER_USER: ${{ secrets.DOCKER_USER }} | |
DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }} | |
run: ./gradlew pushDockerImage |