From 0cb035555f04c3fd735ad1b0cc18679f7025421d Mon Sep 17 00:00:00 2001 From: Sam Catlow Date: Sat, 31 Oct 2026 19:19:49 +1100 Subject: [PATCH] ci(deploy): link the published packages to the repository --- .github/workflows/deploy.yml | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 1bc76b052..808c0d26a 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -402,3 +402,15 @@ jobs: '{tag_name: $tag, name: $name, body: $body, draft: false, prerelease: false}')" \ "$api/repos/$repo/releases" >/dev/null echo "published release notes for $tag" + + # A Gitea package belongs to its owner, not a repository, so the ones this + # workflow publishes are linked here. Linking is per package and a no-op + # once done, so an already linked package is not an error. + - name: Link the packages to this repository + env: + DEPLOY_TOKEN: ${{ secrets.DEPLOY_TOKEN }} + run: | + for name in archied archie-agent archie; do + curl -sS -o /dev/null -X POST -H "Authorization: token $DEPLOY_TOKEN" \ + "https://git.catlow.cloud/api/v1/packages/sam/container/$name/-/link/archie" || true + done