The github action is used to run database migrations. This had been running for 7+ months with no issues, and then in the last week, it can no longer "link". I verified all the secrets, and they are correct.
Error logs:
supabase link --project-ref $SUPABASE_PROJECT_ID
shell: /usr/bin/bash -e {0}
env:
SUPABASE_ACCESS_TOKEN:
SUPABASE_DB_PASSWORD:
SUPABASE_PROJECT_ID: *
SUPABASE_INTERNAL_IMAGE_REGISTRY: ghcr.io
Unexpected error retrieving remote project status: {"message":"Your account does not have the necessary privileges to access this endpoint.
yaml:
name: Deploy Migrations to Staging
on:
push:
branches:
- develop
paths:
- 'supabase/migrations/'
workflow_dispatch:
jobs:
deploy:
name: Run data migrations
runs-on: ubuntu-latest
env:
SUPABASE_ACCESS_TOKEN: ${{ secrets.SUPABASE_ACCESS_TOKEN }}
SUPABASE_DB_PASSWORD: ${{ secrets.STAGING_DB_PASSWORD }}
SUPABASE_PROJECT_ID: ${{ secrets.PRODUCTION_PROJECT_ID }}
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up Supabase CLI
uses: supabase/setup-cli@v1
with:
version: latest
- name: Link Supabase project
run: supabase link --project-ref $SUPABASE_PROJECT_ID
- name: Apply database migrations
run: supabase db push --include-all
# include-all ensures all migrations are applied