Skip to content

ci: fix

ci: fix #12

Workflow file for this run

name: Stromae V1 - build docker
on:
push:
branches:
- 'v1-orbeon-2022'
jobs:
build:
runs-on: ubuntu-latest
outputs:
stromae-version: ${{ steps.version-step.outputs.version }}
steps:
- uses: actions/checkout@v2
- name: Set up JDK 17
uses: actions/setup-java@v1
with:
java-version: 17
- name: script download and clean Orbeon
run: |
chmod +x ./script/getCleanedOrbeon.sh
./script/getCleanedOrbeon.sh $ORBEON_URL_CE
shell: bash
env:
ORBEON_URL_CE: https://github.com/orbeon/orbeon-forms/releases/download/tag-release-2023.1-ce/orbeon-2023.1.202312312000-CE.zip
- name: Get Version
id: version-step
run: echo "version=$(mvn -f pom.xml help:evaluate -Dexpression=project.version -q -DforceStdout)" >> $GITHUB_OUTPUT
- name: Print Version
run: echo ${{ steps.version-step.outputs.version }}
- name: Build with Maven
run: mvn clean install
- name: Upload war
uses: actions/upload-artifact@v2
with:
name: war
path: target/*.war
docker:
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Download build
id: download
uses: actions/download-artifact@v2
with:
name: war
path: target/
- name: Publish to Registry
uses: elgohr/Publish-Docker-Github-Action@v5
with:
name: inseefr/stromae
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
default_branch: ${{ github.ref }}
tags: ${{ needs.build.outputs.stromae-version }}