# https://webui.me # https://github.com/webui-dev/webui # Copyright (c) 2020-2025 Hassan Draga. # Licensed under MIT License. # All rights reserved. # Canada. name: Linux-RedHat on: workflow_call: jobs: build: runs-on: ubuntu-latest strategy: matrix: include: - cc: gcc arch: x64 - cc: clang arch: x64 fail-fast: false env: ARTIFACT: webui-linux-redhat-${{ matrix.cc }}-${{ matrix.arch }} CC: ${{ matrix.cc }} steps: - name: Check out the repository uses: actions/checkout@v4 - name: Set up Docker Buildx uses: docker/setup-buildx-action@v2 - name: Build RedHat Docker Image run: | docker build -t redhat:latest - < github.repository_owner == 'webui-dev' && (github.ref_type == 'tag' || (github.ref_name == 'main' && github.event_name == 'push')) run: | zip -r "$ARTIFACT.zip" "$ARTIFACT" if [ $GITHUB_REF_TYPE == tag ]; then echo "TAG=$GITHUB_REF_NAME" >> $GITHUB_ENV else { echo "IS_PRERELEASE=true"; echo "TAG=nightly"; echo "TITLE=WebUI Nightly Build $(date -u +'%Y-%m-%d %H:%M:%S UTC')" echo "BODY=Generated from commit $GITHUB_SHA." } >> $GITHUB_ENV fi - name: Update Nightly Tag if: env.IS_PRERELEASE uses: richardsimko/update-tag@v1 env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} with: tag_name: nightly - name: Release if: > github.repository_owner == 'webui-dev' && (github.ref_type == 'tag' || (github.ref_name == 'main' && github.event_name == 'push')) uses: ncipollo/release-action@v1 with: artifacts: ${{ env.ARTIFACT }}.zip tag: ${{ env.TAG }} body: ${{ env.BODY }} name: ${{ env.TITLE }} prerelease: ${{ env.IS_PRERELEASE }} allowUpdates: true