-
Notifications
You must be signed in to change notification settings - Fork 1
89 lines (73 loc) · 2.31 KB
/
gradle.yml
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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
# This workflow will build a Java project with Gradle
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-gradle
name: Java CI with Gradle
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Setup Java JDK
uses: actions/setup-java@v4
with:
distribution: 'zulu'
java-version: '21'
cache: 'gradle'
- name: Setup Node.js environment
uses: actions/[email protected]
with:
node-version: 20
- name: Login to Docker Hub
uses: docker/[email protected]
if: github.actor != 'dependabot[bot]'
with:
username: ${{ secrets.DOCKER_HUB_USERNAME }}
password: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }}
- name: print versions
run: |
java -version
node --version
npm --version
docker version
docker info
ip a
- name: Initialize CodeQL
uses: github/codeql-action/init@v3
with:
languages: java, javascript
- name: Build with Gradle
run: ./gradlew build --no-daemon
env:
HOST_FOR_SELENIUM: "172.17.0.1"
- name: Publish Unit Test Results
uses: EnricoMi/publish-unit-test-result-action@v2
if: github.actor != 'dependabot[bot]'
with:
files: build/test-results/test/*.xml
- name: publish screenshots
uses: actions/upload-artifact@v4
if: always()
with:
name: screenshots
path: build/screenshot/
- name: publish spotbugs
if: github.actor != 'dependabot[bot]'
uses: jwgmeligmeyling/spotbugs-github-action@master
with:
path: 'build/reports/spotbugs/*.xml'
- name: publish pmd
if: github.actor != 'dependabot[bot]'
uses: jwgmeligmeyling/pmd-github-action@master
with:
path: 'build/reports/pmd/*.xml'
- name: code coverage
uses: codecov/codecov-action@v5
if: always()
- name: build docker image
run: docker build -t demo-spring-jsf .
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3