# Stirling-PDF SaaS environment defaults. Committed, non-secret. Real values for secrets go in # .env.saas.local, which is loaded first and wins. Do not commit that file. # # Three environments, each deriving its Supabase URLs, JWT issuer and JWKS from one project ref: # # prod PROFILES=none SAAS_DB_* the live project # staging PROFILES=staging SAAS_STAGING_* pinned to v3, always there # dev PROFILES=dev SAAS_DEV_* follows a SaaS PR's preview branch # # dev is the default for `task backend:dev:saas`. Use staging for somewhere stable; use dev when # testing an open SaaS PR, since its preview branch is the only place those migrations are applied. # ---------- Supabase project (prod / no-profile) ---------- # Project reference (the subdomain part of .supabase.co). Required. # Set in .env.saas.local. SAAS_DB_PROJECT_REF= # Edge function secret used by billing/license rollup calls. Set in .env.saas.local. SUPABASE_EDGE_FUNCTION_SECRET= # ---------- Database (no profile) ---------- # Direct JDBC URL to the Supabase Postgres. Required when running without # `--spring.profiles.include=...`. # Example: jdbc:postgresql://db..supabase.co:5432/postgres SAAS_DB_URL= SAAS_DB_USERNAME=postgres SAAS_DB_PASSWORD= # ---------- staging profile ---------- # The shared long-lived v3 project. application-staging.properties defaults the ref, # URL, database host and meter endpoint, so staging needs only the password, in # .env.saas.local. Set SAAS_STAGING_PROJECT_REF to repoint it; everything derives. # # The ref and publishable key are duplicated here because the task derives the # frontend's VITE_SUPABASE_* from them and a shell cannot read a Spring default. # Neither is secret: the ref is a public subdomain, the key ships in the bundle. SAAS_STAGING_PROJECT_REF=qacaivhsjtftfwtgjvva SAAS_STAGING_PUBLISHABLE_KEY=sb_publishable_nIM8y-9ARPE7EzQwAQHKMg_40fCN6kY # gitleaks:allow SAAS_STAGING_DB_USERNAME=postgres SAAS_STAGING_DB_PASSWORD= # ---------- dev profile ---------- # The SaaS PR's Supabase preview branch. Take the ref from that PR's "Supabase # Preview" check; the profile derives URL, JWT issuer, JWKS, meter endpoint and # database host from it, so this one value follows a different PR. # # A preview branch has its own password and keys; the parent project's will not # authenticate. Both go in .env.saas.local, along with the ref. SAAS_DEV_PROJECT_REF= SAAS_DEV_PUBLISHABLE_KEY= SAAS_DEV_DB_USERNAME=postgres SAAS_DEV_DB_PASSWORD=