Skip to content

PR Build

PR Build #5

Workflow file for this run

name: PR Build
# PR build
on:
pull_request:
branches: [ master, versionupgrade ]
workflow_dispatch:
# just runs Maven and Docker build
jobs:
build:
name: "PR build"
runs-on: [self-hosted, linux, X64]
steps:
- name: checkout
uses: actions/checkout@v2
- name: Set up JDK 17
uses: actions/setup-java@v3
with:
distribution: 'zulu'
java-version: 17
- name: Set up Maven
uses: stCarolas/[email protected]
with:
maven-version: 3.9.2
- name: get version from pom.xml
run: |
echo "VERSION=$( mvn help:evaluate -Dexpression=project.version -q -DforceStdout )" >> $GITHUB_ENV
- name: Build with Maven
run: mvn clean -B package -P frontend --file pom.xml
env:
CI: false
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Build and push
uses: docker/build-push-action@v5
with:
context: .
file: ./dockerfile
push: false
tags: ${{ env.DOCKERHUB_ORG }}/databackend:${{ env.VERSION }}