Skip to content

app-users

app-users #10331

Workflow file for this run

name: Gradle Build
on:
push:
repository_dispatch:
types: [app-main, app-users, app-applications, app-standardidprovider, app-xp-welcome]
concurrency: build-${{ github.event.client_payload.ref || github.ref }}
jobs:
publish_vars:
runs-on: ubuntu-latest
outputs:
publish: ${{ steps.publish_vars.outputs.release != 'true' && (env.ACTUAL_GITHUB_REF == 'refs/heads/master' || startsWith(env.ACTUAL_GITHUB_REF, 'refs/heads/7.')) }}
repo: ${{ steps.publish_vars.outputs.repo }}
steps:
- name: Extract actual github.ref
run: echo "ACTUAL_GITHUB_REF=${ACTUAL_REF}" >> $GITHUB_ENV
env:
ACTUAL_REF: ${{ github.event.client_payload.ref || github.ref }}
- uses: actions/checkout@v4
with:
ref: ${{ github.event.client_payload.ref || github.ref }}
- name: Get publishing variables
id: publish_vars
uses: enonic/release-tools/publish-vars@master
env:
PROPERTIES_PATH: './gradle.properties'
build:
strategy:
matrix:
type: [sdk, server]
os: [mac, mac-arm64, linux, linux-arm64, windows]
include:
- type: server
os: generic
runs-on: ubuntu-latest
needs: publish_vars
if: needs.publish_vars.outputs.publish == 'true'
steps:
- uses: actions/checkout@v4
with:
ref: ${{ github.event.client_payload.ref || github.ref }}
- uses: actions/setup-java@v4
with:
java-version: 17.0.7
distribution: 'temurin'
cache: gradle
- name: Publish
run: ./gradlew publish -Pos=${{ matrix.os }} -Ptype=${{ matrix.type }} -PrepoKey=${{ needs.publish_vars.outputs.repo }} -PrepoUser=${{ secrets.ARTIFACTORY_USERNAME }} -PrepoPassword=${{ secrets.ARTIFACTORY_PASSWORD }}