Managed Supabase, Environment Isolation & Migrations

Provision physically isolated development and production Managed Supabase environments with automated backups and SQL migrations.

Physical Dev vs. Prod Environment Isolation

When you enable a backend during development, Baselift binds an isolated development Managed Supabase environment and syncs credentials directly to your workspace .env.local.

When you publish your project for the first time, Baselift automatically provisions a physically separate production Managed Supabase environment so workspace schema experiments never affect live user data.

Ordered SQL Migrations & Pre-Publish Backups

Place repeatable or incremental SQL migration files inside supabase/migrations/ (for example, supabase/migrations/001_init.sql).

Before applying migrations during publish, Baselift automatically snapshots your production environment and executes ordered SQL migrations cleanly.

コード例
-- supabase/migrations/001_notes.sql
CREATE TABLE IF NOT EXISTS public.notes (
  id uuid PRIMARY KEY DEFAULT gen_random_uuid(),
  user_id uuid NOT NULL DEFAULT auth.uid(),
  content text NOT NULL,
  created_at timestamptz NOT NULL DEFAULT now()
);

ALTER TABLE public.notes ENABLE ROW LEVEL SECURITY;
CREATE POLICY "notes_owner_policy" ON public.notes
  FOR ALL USING (auth.uid() = user_id);