From 6c3aad2f8295616c79eebc2e3061f0ea20f70782 Mon Sep 17 00:00:00 2001 From: Felix Matouschek Date: Wed, 9 Aug 2023 09:52:46 +0200 Subject: [PATCH 1/2] release: Run other workflows explicitly To bypass restrictions on GitHub Actions run the docs and ci workflows manually after creating a release. GitHub Actions does not trigger other workflows from a workflow run if not using a personal access token (PAT). By calling the workflows explicitly, it is possible to work around this restriction without the need for a PAT. Signed-off-by: Felix Matouschek --- .github/workflows/ci.yml | 1 + .github/workflows/release.yml | 12 ++++++++++++ 2 files changed, 13 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index c404451..cf853b6 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -7,6 +7,7 @@ on: branches: - main pull_request: + workflow_dispatch: schedule: - cron: '0 6 * * *' jobs: diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 67c385b..8a19efa 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -89,3 +89,15 @@ jobs: tag_name: ${{ steps.get_version.outputs.TAG_VERSION }} files: "*.tar.gz" body_path: gh-release.md + + - name: Run docs workflow + run: | + gh workflow run docs.yml --ref main + gh workflow run docs.yml --ref ${{ steps.get_version.outputs.TAG_VERSION }} + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + + - name: Run ci workflow + run: gh workflow run ci.yml --ref main + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} From c42749e9d1a927db172232d4bad2c998bbbcc200 Mon Sep 17 00:00:00 2001 From: Felix Matouschek Date: Wed, 9 Aug 2023 10:14:01 +0200 Subject: [PATCH 2/2] fix: Use kubevirt-bot in release workflow Signed-off-by: Felix Matouschek --- .github/workflows/release.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 8a19efa..2065195 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -76,8 +76,8 @@ jobs: - name: Create release tag run: | - git config user.name github-actions - git config user.email github-actions@github.com + git config user.name kubevirt-bot + git config user.email kubevirtbot@redhat.com git tag -a ${{ steps.get_version.outputs.TAG_VERSION }} -m "Release v${{ steps.get_version.outputs.TAG_VERSION }}" || true git push origin --tags