-
Notifications
You must be signed in to change notification settings - Fork 354
39 lines (33 loc) · 1.17 KB
/
hello-world.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
name: Hello World Pipeline
on:
pull_request:
# For this to work, this workflow needs to be on master https://docs.github.com/en/actions/writing-workflows/choosing-when-your-workflow-runs/events-that-trigger-workflows#workflow_run
# workflow_run:
# workflows: ["Check formatting"]
# types:
# - completed
jobs:
say-hello:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up JDK 17
uses: actions/setup-java@v4
with:
java-version: 17
distribution: temurin
# Set up Maven
- name: Set up Maven
run: |
sudo apt-get install maven
echo "On branch: $GITHUB_REF_NAME"
echo "Git commit: ${{ github.sha }}""
# Run Maven build
- name: Build with Maven
run: mvn --threads 4 --batch-mode --no-transfer-progress clean install --update-snapshots --file ./dhis-2/pom.xml -DskipTests
- name: Sync war
run: |
echo "Syncing WAR ..."
curl "https://raw.githubusercontent.com/dhis2/dhis2-server-setup/master/ci/scripts/copy-war-s3.sh" -O
chmod +x copy-war-s3.sh
./copy-war-s3.sh dev $GITHUB_REF_NAME