-
Notifications
You must be signed in to change notification settings - Fork 2
99 lines (75 loc) · 2.06 KB
/
build.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
90
91
92
93
94
95
96
97
98
99
name: Build (npm + maven) + Report
on: [push]
concurrency:
group: ${{ github.workflow }}-${{ github.sha }}
cancel-in-progress: true
jobs:
build-frontend:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [16.x]
steps:
- uses: actions/checkout@v3
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
- name: Update npm dependencies
run: ./build.sh --npm
- name: Build jsx
run: ./build.sh --jsx-force
- uses: actions/upload-artifact@v3
with:
name: frontend-artifact
path: src/main/resources/assets
build-backend:
needs: build-frontend
runs-on: ubuntu-latest
strategy:
matrix:
java-version: [11.x]
steps:
- uses: actions/checkout@v3
- name: Use Java ${{ matrix.java-version }}
uses: actions/setup-java@v3
with:
java-version: ${{ matrix.java-version }}
distribution: 'temurin'
cache: maven
- name: Fetch frontend build result
uses: actions/download-artifact@v3
with:
name: frontend-artifact
- name: Build jar
#run: ./build.sh --jar
run: mvn -ntp clean package
- name: Prepare build artifact for packaging
run: |
mkdir -p staging/target
cp aggregator.yml staging/
cp target/aggregator-*.jar staging/target/
- uses: actions/upload-artifact@v3
with:
name: Package
path: staging
mvn-site-report:
runs-on: ubuntu-latest
continue-on-error: true
steps:
- uses: actions/checkout@v3
- name: Use Java 11
uses: actions/setup-java@v3
with:
java-version: '11'
distribution: 'temurin'
cache: maven
# XXX: for _now_ does not need access to built frontend artifact, e.g. for tests or similar
- name: Generate report
run: |
mvn -ntp clean site
mv target/site report
- uses: actions/upload-artifact@v3
with:
name: Report
path: report