From 6f2e7291e8ed3a2f60dbe62e9e10d35bdf5ef469 Mon Sep 17 00:00:00 2001 From: svemagie <869694+svemagie@users.noreply.github.com> Date: Sat, 21 Mar 2026 07:56:53 +0100 Subject: [PATCH] fix(deploy): use SITE_URL for syndication webhook me claim and endpoint - me claim must be the publication URL (SITE_URL), not a separate INDIEKIT_URL - SITE_URL is already a configured secret in this repo - Show HTTP response body and status code for easier debugging Co-Authored-By: Claude Sonnet 4.6 --- .github/workflows/deploy.yml | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 47ba45e..56d6be8 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -132,20 +132,24 @@ jobs: - name: Trigger syndication webhook env: SECRET: ${{ secrets.SECRET }} - INDIEKIT_URL: ${{ secrets.INDIEKIT_URL }} + SITE_URL: ${{ secrets.SITE_URL }} run: | npm install --no-save jsonwebtoken TOKEN=$(node --input-type=commonjs <<'EOF' const jwt = require('jsonwebtoken'); const token = jwt.sign( - { me: process.env.INDIEKIT_URL, scope: 'update' }, + { me: process.env.SITE_URL, scope: 'update' }, process.env.SECRET, { expiresIn: '10m' } ); process.stdout.write(token); EOF ) - curl -sf -X POST \ + RESPONSE=$(curl -sS -w "\n%{http_code}" -X POST \ -H "Content-Type: application/json" \ -d "{\"access_token\": \"$TOKEN\"}" \ - "$INDIEKIT_URL/syndicate" + "$SITE_URL/syndicate") + HTTP_CODE=$(echo "$RESPONSE" | tail -1) + BODY=$(echo "$RESPONSE" | head -n -1) + echo "HTTP $HTTP_CODE: $BODY" + [ "$HTTP_CODE" -lt 400 ]