-
Notifications
You must be signed in to change notification settings - Fork 169
130 lines (118 loc) · 3.87 KB
/
simple-build-test.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
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
name: Basic build and test
env:
MANDREL_VERSION: "23.0.1.2-Final"
on:
push:
paths-ignore:
- 'deploy/**'
- '**/*.md'
- 'docs/**'
- '**/images/**'
- '.github/dependabot.yml'
- '.github/quarkus-ecosystem-test'
- '.github/workflows/quarkus-snapshot.yaml'
- '.github/workflows/build-push-ui-images.yml'
- 'scripts/deploy-to-azure-containerapps.sh'
- 'scripts/watch-services.sh'
- '**/hyperfoil/**'
branches:
- main
pull_request:
types:
- opened
- synchronize
- reopened
- ready_for_review
branches:
- main
paths-ignore:
- 'deploy/**'
- '**/*.md'
- 'docs/**'
- '**/images/**'
- '.github/dependabot.yml'
- '.github/build-push-container-images*.yml'
- '.github/quarkus-ecosystem-test'
- '.github/workflows/quarkus-snapshot.yaml'
- '.github/workflows/build-push-ui-images.yml'
- 'scripts/*.sh'
- '**/hyperfoil/**'
workflow_dispatch:
concurrency:
group: "workflow = ${{ github.workflow }}, ref = ${{ github.event.ref }}, pr = ${{ github.event.pull_request.id }}"
cancel-in-progress: ${{ github.event_name == 'pull_request' }}
jobs:
jvm-build-test:
runs-on: ubuntu-latest
if: github.repository == 'quarkusio/quarkus-super-heroes'
strategy:
fail-fast: false
matrix:
java:
- '17'
project:
- event-statistics
- rest-fights
- rest-heroes
- rest-villains
- rest-narration
- ui-super-heroes
name: "build-test-${{ matrix.project }}-${{ matrix.java }}"
steps:
- uses: actions/checkout@v4
- name: Setup Java ${{ matrix.java }}
uses: actions/setup-java@v3
with:
java-version: ${{ matrix.java }}
distribution: temurin
cache: maven
- name: "build-test-jvm-${{ matrix.project }}-java-${{ matrix.java }}"
working-directory: ${{ matrix.project }}
run: |
./mvnw -B clean verify \
-Dquarkus.http.host=0.0.0.0 \
-Dmaven.compiler.release=${{ matrix.java }}
native-build-test:
runs-on: ubuntu-latest
if: github.repository == 'quarkusio/quarkus-super-heroes'
strategy:
fail-fast: false
matrix:
java:
- '17'
project:
- event-statistics
- rest-fights
- rest-heroes
- rest-villains
# Until https://github.com/microsoft/semantic-kernel/issues/2885 is resolved
# - rest-narration
- ui-super-heroes
name: "native-build-test-${{ matrix.project }}"
steps:
- uses: actions/checkout@v4
- name: Cache and restore Mandrel distro
id: check-mandrel-cache
uses: actions/cache@v3
with:
path: mandrel-${{ env.MANDREL_VERSION }}-${{ matrix.java }}.tar.gz
key: mandrel-distro-${{ env.MANDREL_VERSION }}-${{ matrix.java }}
- name: Download Mandrel
if: steps.check-mandrel-cache.outputs.cache-hit != 'true'
run: |
download_url="https://github.com/graalvm/mandrel/releases/download/mandrel-${MANDREL_VERSION}/mandrel-java${{ matrix.java }}-linux-amd64-${MANDREL_VERSION}.tar.gz"
wget -q -O mandrel-${{ env.MANDREL_VERSION }}-${{ matrix.java }}.tar.gz $download_url
- name: Setup Maven+OpenJDK Distro
uses: actions/setup-java@v3
with:
distribution: 'jdkfile'
jdkFile: mandrel-${{ env.MANDREL_VERSION }}-${{ matrix.java }}.tar.gz
java-version: ${{ matrix.java }}
architecture: x64
cache: maven
- name: "build-test-native-${{ matrix.project }}-java-${{ matrix.java }}"
working-directory: ${{ matrix.project }}
run: |
./mvnw -B clean verify -Pnative \
-Dquarkus.http.host=0.0.0.0 \
-Dmaven.compiler.release=${{ matrix.java }}