-
Notifications
You must be signed in to change notification settings - Fork 22
63 lines (52 loc) · 1.53 KB
/
example.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
name: Example DockerHub Release
on:
workflow_dispatch:
inputs:
subdir:
description: 'Subdirectory'
required: false
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Setup JDK 8
uses: AdoptOpenJDK/install-jdk@v1
with:
version: '8'
architecture: x64
targets: 'JAVA_8_HOME'
- name: Setup JDK 11
uses: AdoptOpenJDK/install-jdk@v1
with:
version: '11'
architecture: x64
targets: 'JAVA_11_HOME'
- name: Setup JDK 17
uses: AdoptOpenJDK/install-jdk@v1
with:
version: '17'
architecture: x64
targets: 'JAVA_17_HOME;JAVA_HOME'
- name: Install xmllint
run: sudo apt-get install libxml2-utils
- name: Get version
id: get_version
run: echo ::set-output name=VERSION::${GITHUB_REF/refs\/tags\//}
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
with:
config-inline: |
insecure-entitlements = [ "network.host" ]
- name: Log in to Docker Hub
uses: docker/login-action@v1
with:
username: ${{ secrets.POLARIS_DOCKER_NAME }}
password: ${{ secrets.POLARIS_DOCKER_PASSWORD }}
- name: Build
id: build
run: |
export use_docker_env=false
pushd polaris-agent-build/bin
bash ./build.sh
bash ./build_example_docker.sh ${{ github.event.inputs.subdir }}