-
Notifications
You must be signed in to change notification settings - Fork 0
108 lines (96 loc) · 2.7 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
100
101
102
103
104
105
106
107
108
name: Build
on:
push:
branches:
- "main"
paths-ignore:
- '.gitignore'
- 'CODEOWNERS'
- 'LICENSE'
- '*.md'
- '*.adoc'
- '*.txt'
- '.all-contributorsrc'
pull_request:
paths-ignore:
- '.gitignore'
- 'CODEOWNERS'
- 'LICENSE'
- '*.md'
- '*.adoc'
- '*.txt'
- '.all-contributorsrc'
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
defaults:
run:
shell: bash
jobs:
build:
name: Build on ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
# os: [windows-latest, macos-latest, ubuntu-latest]
os: [ubuntu-latest]
runs-on: ${{ matrix.os }}
services:
redis:
image: redis
options: >-
--health-cmd "redis-cli ping"
--health-interval 10s
--health-timeout 5s
--health-retries 5
ports:
- 6379:6379
environment: deploy-setting.xml
steps:
- name: Prepare git
run: git config --global core.autocrlf false
if: startsWith(matrix.os, 'windows')
- uses: actions/checkout@v3
- name: Import GPG key
id: import_gpg
uses: crazy-max/ghaction-import-gpg@v6
with:
gpg_private_key: ${{ secrets.GPG_PRIVATE_KEY }}
passphrase: ${{ secrets.GPG_PASSPHRASE }}
- name: Set up JDK 17
uses: actions/setup-java@v3
with:
distribution: temurin
java-version: 17
# cache: 'maven'
- name: Set up OSSRH
uses: actions/setup-java@v3
with:
distribution: temurin
java-version: 17
# cache: 'maven'
server-id: ossrh
server-username: ${{ vars.SERVER_OSSRH_USERNAME }}
server-password: ${{ secrets.SERVER_OSSRH_PASSWORD }}
- name: Set up CENTRAL
uses: actions/setup-java@v3
with:
distribution: temurin
java-version: 17
# cache: 'maven'
server-id: central
server-username: ${{ vars.SERVER_CENTRAL_USERNAME }}
server-password: ${{ secrets.SERVER_CENTRAL_PASSWORD }}
- name: Set up PROFILE
uses: actions/setup-java@v3
with:
distribution: temurin
java-version: 17
# cache: 'maven'
profile-id: ossrh
profile-properties-gpg.executable: ${{ vars.PROFILE_OSSRH_GPG_EXECUTABLE }}
profile-properties-gpg.passphrase: ${{ secrets.GPG_PASSPHRASE }}
- name: Build with Maven
run: mvn -B clean install -Dno-format
- name: Build with Maven (Native)
run: mvn -B install -Dnative -Dquarkus.native.container-build -Dnative.surefire.skip