-
Notifications
You must be signed in to change notification settings - Fork 31
32 lines (29 loc) · 1.12 KB
/
ci.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
name: CI
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
release:
types: [published]
jobs:
validate:
uses: mekomsolutions/shared-github-workflow/.github/workflows/maven-build-test.yml@main
with:
java-version: "8"
maven-phase: "install"
maven-args: "-Pvalidator -Pbundled-docker" # Validate OpenMRS configs & build Docker images embedding the distro bins and configs
secrets:
NEXUS_USERNAME: ${{ secrets.NEXUS_USERNAME }}
NEXUS_PASSWORD: ${{ secrets.NEXUS_PASSWORD }}
release:
if: ${{ (github.event_name == 'push' && github.ref == 'refs/heads/main') || github.event_name == 'release' }}
needs: validate
uses: mekomsolutions/shared-github-workflow/.github/workflows/maven-publish.yml@main
with:
maven-args: "-Pbundled-docker" # Build Docker images embedding the distro bins and configs
secrets:
NEXUS_USERNAME: ${{ secrets.NEXUS_USERNAME }}
NEXUS_PASSWORD: ${{ secrets.NEXUS_PASSWORD }}
DOCKER_HUB_USERNAME: ${{ secrets.DOCKER_HUB_REGISTRY_USERNAME }}
DOCKER_HUB_PASSWORD: ${{ secrets.DOCKER_HUB_REGISTRY_PASSWORD }}