From 1db6742a7ef8e7429f418ab58546dd229e2c66b6 Mon Sep 17 00:00:00 2001 From: Andy Scherzinger Date: Tue, 7 Jul 2026 19:55:39 +0200 Subject: [PATCH] ci: Add release relay action Assisted-by: Claude:claude-fable-5 Signed-off-by: Andy Scherzinger --- .../release-relay.properties.json | 5 +++ workflow-templates/release-relay.yml | 38 +++++++++++++++++++ 2 files changed, 43 insertions(+) create mode 100644 workflow-templates/release-relay.properties.json create mode 100644 workflow-templates/release-relay.yml diff --git a/workflow-templates/release-relay.properties.json b/workflow-templates/release-relay.properties.json new file mode 100644 index 00000000..53bdc97a --- /dev/null +++ b/workflow-templates/release-relay.properties.json @@ -0,0 +1,5 @@ +{ + "name": "Release Relay", + "description": "Dispatches the repository information and tag of a release to a relay for further release processing", + "iconName": "octicon robot" +} diff --git a/workflow-templates/release-relay.yml b/workflow-templates/release-relay.yml new file mode 100644 index 00000000..08908315 --- /dev/null +++ b/workflow-templates/release-relay.yml @@ -0,0 +1,38 @@ +# This workflow is provided via the organization template repository +# +# https://github.com/nextcloud/.github +# https://docs.github.com/en/actions/learn-github-actions/sharing-workflows-with-your-organization +# +# SPDX-FileCopyrightText: 2026 Nextcloud GmbH and Nextcloud contributors +# SPDX-License-Identifier: MIT + +name: Notify release-relay on release + +on: + release: + types: [published] + +permissions: + contents: read + +jobs: + notify: + name: Dispatch release to release-relay + runs-on: ubuntu-latest + + # Only allowed to run on nextcloud-releases repositories + if: ${{ github.repository_owner == 'nextcloud-releases' }} + + steps: + - name: Check actor permission + uses: skjnldsv/check-actor-permission@69e92a3c4711150929bca9fcf34448c5bf5526e7 # v3.0 + with: + require: write + + - name: Dispatch to release-relay + uses: peter-evans/repository-dispatch@28959ce8df70de7be546dd1250a005dd32156697 # v4.0.1 + with: + token: ${{ secrets.DISPATCH_PAT }} + repository: nextcloud-gmbh/release-relay + event-type: app-tagged + client-payload: '{"app": "${{ github.repository }}", "tag": "${{ github.event.release.tag_name }}"}'