- Migration 20260825000000_interfaces.sql: external_id on contacts/ registrations/sessions (+ partial unique indexes), slots_id_seq, sync_runs audit table, and service-role-only sync_pretix_attendees / sync_sessionize_sessions RPCs (idempotent upserts). - sync-trigger Edge Function: admin-JWT or CRON_SECRET auth, pulls from Pretix/Sessionize base URLs, normalizes, calls the service-role RPCs. - interfaces/mock-api: dependency-free Node server (:54330) + fixtures so the full pipeline is testable without real tokens. - APPE Admin 'Interfaces' view: per-source + 'Sync all' triggers, result counts, recent sync runs, and QR CSV export; /functions proxy added. - Docs: new docs/backend/interfaces.md; updated README, roadmap, next-steps, schema, rls, rpcs, architecture, admin-app, and docs index. Co-authored-by: Stephan Charles <[email protected]> Co-authored-by: Amelia Hernandez <[email protected]> Co-authored-by: Markus Franz <[email protected]> Co-authored-by: Sabrina Hota <[email protected]> Co-authored-by: Nilüfer Doğan <[email protected]>
22 lines
749 B
TypeScript
22 lines
749 B
TypeScript
import { defineConfig } from 'vite';
|
|
import react from '@vitejs/plugin-react';
|
|
|
|
// Dev server proxies /auth, /rest, /realtime, /storage to the local Supabase
|
|
// stack so the app can use relative URLs (works in Docker + localhost).
|
|
const SUPABASE_TARGET = 'http://127.0.0.1:54321';
|
|
|
|
export default defineConfig({
|
|
plugins: [react()],
|
|
server: {
|
|
host: true,
|
|
port: 3001,
|
|
proxy: {
|
|
'/auth': { target: SUPABASE_TARGET, changeOrigin: true },
|
|
'/rest': { target: SUPABASE_TARGET, changeOrigin: true },
|
|
'/realtime': { target: SUPABASE_TARGET, changeOrigin: true, ws: true },
|
|
'/storage': { target: SUPABASE_TARGET, changeOrigin: true },
|
|
'/functions': { target: SUPABASE_TARGET, changeOrigin: true },
|
|
},
|
|
},
|
|
});
|