-
Notifications
You must be signed in to change notification settings - Fork 132
40 lines (33 loc) · 888 Bytes
/
main.yml
File metadata and controls
40 lines (33 loc) · 888 Bytes
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
name: Build and Deploy WAR
on:
push:
tags:
- 'v[0-9]+.[0-9]+'
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up JDK 14
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '21'
- name: Build WAR
run: jar cvf helloworld.war WEB-INF
- name: Display WAR file
run: ls helloworld.war
- name: Deploy WAR
run: |
mkdir -p deployment
cp helloworld.war deployment/
- name: Upload binaries to release
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: helloworld.war
asset_name: helloworld.war
tag: ${{ github.ref }}
overwrite: true
body: "HAve fun :)"