deb release [nightly, master@7e99b4f86d068edf8829667a4eb2443087b88334] #29
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Deb Release | |
run-name: | | |
deb release [${{github.ref_type == 'branch' && 'nightly' || 'stable'}}, ${{github.ref_name}}${{github.ref_type == 'branch' && '@' || ''}}${{github.ref_type == 'branch' && github.sha || ''}}] | |
on: | |
workflow_dispatch: | |
push: | |
tags: | |
- '*' | |
- '!*/**' | |
workflow_run: | |
workflows: ["Release"] | |
types: [completed] | |
concurrency: | |
group: deb-release-${{ github.ref }} | |
cancel-in-progress: true | |
permissions: | |
contents: write | |
packages: read | |
jobs: | |
check-trigger: | |
runs-on: ubuntu-latest | |
outputs: | |
DO_BUILD: ${{steps.config.outputs.DO_BUILD}} | |
steps: | |
- name: "Generate test configuration" | |
id: config | |
run: | | |
if [ \( "${{github.event_name}}" = workflow_run -a "${{github.ref_name}}" = master \) \ | |
-o "${{github.ref_type}}" = tag ]; then | |
do_build=y | |
fi | |
( | |
echo DO_BUILD=${do_build} | |
) >> ${GITHUB_OUTPUT} | |
- name: "Fail if upstream job failed" | |
run: | | |
echo "upstream job for ${{github.ref_type}} ${{github.ref_name}} failed with conclusion '${{github.event.workflow_run.conclusion}}'" | |
exit 1 | |
if: github.event_name == 'workflow_run' && steps.config.outputs.DO_BUILD && github.event.workflow_run.conclusion != 'success' | |
build-packages: | |
needs: check-trigger | |
if: needs.check-trigger.outputs.DO_BUILD | |
strategy: | |
matrix: | |
base-tag: ["ubuntu:22.04"] | |
platform: [amd64, arm64] | |
uses: ./.github/workflows/_deb_build.yml | |
secrets: inherit | |
with: | |
base-tag: ${{ matrix.base-tag }} | |
platform: ${{ matrix.platform }} | |
publish_release: | |
needs: build-packages | |
if: github.ref_type == 'tag' | |
runs-on: ubuntu-latest | |
steps: | |
- name: Download all artifacts | |
uses: actions/download-artifact@v4 | |
- name: Create new release | |
uses: softprops/action-gh-release@v2 | |
with: | |
files: | | |
uno-deb-*-amd64__*/*.deb | |
uno-deb-*-arm64__*/*.deb |