forked from joelhockey/jacknji11
-
Notifications
You must be signed in to change notification settings - Fork 0
34 lines (34 loc) · 1.05 KB
/
release.yaml
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
name: Create a GitHub release
on:
push:
tags:
- "v[0-9]+.[0-9]+.[0-9]+"
branches:
- "ci/create-releases"
jobs:
maven:
name: Maven
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Java
uses: actions/setup-java@v3
with:
java-version: '11'
distribution: 'temurin'
- name: Setup SoftHSM
run: |
sudo apt install softhsm2
SLOT_ID=$(softhsm2-util --init-token --free --label "test" --pin 1234 --so-pin 1234 | tail -n 1 | awk '{ print $NF }')
export JACKNJI11_TEST_TESTSLOT="$SLOT_ID"
export JACKNJI11_TEST_INITSLOT="$SLOT_ID"
export JACKNJI11_TEST_USER_PIN=1234
export JACKNJI11_TEST_SO_PIN=1234
export JACKNJI11_PKCS11_LIB_PATH=/usr/lib64/libsofthsm2.so
- name: Build and test
run: mvn package
- name: Release
uses: softprops/action-gh-release@v1
with:
files: target/*.jar