-
-
Notifications
You must be signed in to change notification settings - Fork 123
63 lines (55 loc) · 1.91 KB
/
Copy pathmvn-deploy.yml
File metadata and controls
63 lines (55 loc) · 1.91 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
name: Java CI - deploy
on:
workflow_dispatch:
push:
branches:
- main
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: xembly/workflow-manager@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
run: clean, cancel
verbose: false
- uses: actions/checkout@v3.0.2
- uses: actions/setup-python@v4
- uses: pre-commit/action@v3.0.0
- name: Login to Docker Hub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Set up JDK 11
uses: actions/setup-java@v3
with:
distribution: "temurin"
java-version: 11
cache: 'maven'
server-id: ossrh
server-username: MAVEN_USERNAME
server-password: MAVEN_PASSWORD
- name: Publish to OSS and Docker hub
run: mvn deploy -Pintegration -Pcoverage -Pdeploy -Pdocker -pl !e2e --batch-mode --errors --fail-at-end --show-version --file pom.xml
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
MAVEN_USERNAME: ${{ secrets.OSSRH_USERNAME }}
MAVEN_PASSWORD: ${{ secrets.OSSRH_TOKEN }}
DOCKER_USERNAME: ${{ secrets.DOCKER_USERNAME }}
DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }}
- name: Test Reporter
uses: dorny/test-reporter@v1
if: success() || failure()
with:
name: Test Report - ${{ matrix.os }}
path: '**/surefire-reports/TEST*.xml'
list-suites: 'failed'
list-tests: 'failed'
reporter: java-junit
- name: Codacy coverage reporter
if: ${{ matrix.os != 'windows-latest' }}
uses: codacy/codacy-coverage-reporter-action@v1
with:
project-token: ${{ secrets.CODACY_PROJECT_TOKEN }}
coverage-reports: coverage/target/site/jacoco-aggregate/jacoco.xml