-
Notifications
You must be signed in to change notification settings - Fork 25
51 lines (43 loc) · 1.62 KB
/
build_deploy_java_language_bindings.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
name: Build and Deploy Java Language Bindings
on:
push:
branches:
- master
- feat/java-language-bindings-cicd
jobs:
build:
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./models/java
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Load secrets from 1Password
id: onepw_secrets
uses: 1password/[email protected]
with:
export-env: true # Export loaded secrets as environment variables
env:
OP_SERVICE_ACCOUNT_TOKEN: ${{ secrets.OP_SERVICE_ACCOUNT_TOKEN }} # This is required to connect to the vault in our 1Password account.
MAVEN_GPG_PRIVATE_KEY: "op://rbiv7rvkkrsdlpcrz3bmv7nmcu/dkkfywvsr3xq6eyeubq6cldaxi/Private Key"
MAVEN_GPG_PASSPHRASE: "op://rbiv7rvkkrsdlpcrz3bmv7nmcu/dkkfywvsr3xq6eyeubq6cldaxi/password"
- name: Set up JDK
uses: actions/setup-java@v4
with:
java-version: '17.0.11'
distribution: 'temurin'
server-id: ossrh
server-username: MAVEN_USERNAME
server-password: MAVEN_PASSWORD
gpg-private-key: ${{ env.MAVEN_GPG_PRIVATE_KEY }}
gpg-passphrase: ${{ env.MAVEN_GPG_PASSPHRASE }}
- name: Build and package
run: |
mvn install -pl rule-factory
- name: Deploy with Maven
run: mvn -B clean deploy -pl gbfs-java-model -P release
env:
MAVEN_GPG_PASSPHRASE: ${{ env.MAVEN_GPG_PASSPHRASE }}
MAVEN_USERNAME: ${{ secrets.SONATYPE_USERNAME }}
MAVEN_PASSWORD: ${{ secrets.SONATYPE_PASSWORD }}