-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
73 additions
and
29 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
# General supabase access token (all projects) | ||
SUPABASE_ACCESS_TOKEN= | ||
# Supabase Project | ||
SUPABASE_DB_PASSWORD= | ||
SUPABASE_PROJECT_ID= |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
create table "public"."healer" ( | ||
"id" bigint generated by default as identity not null, | ||
"created_at" timestamp with time zone not null default now(), | ||
"name" text not null, | ||
"content" text not null, | ||
"avatar" text | ||
); | ||
|
||
|
||
CREATE UNIQUE INDEX healer_pkey ON public.healer USING btree (id); | ||
|
||
alter table "public"."healer" add constraint "healer_pkey" PRIMARY KEY using index "healer_pkey"; | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
create extension if not exists "citext" with schema "public" version '1.6'; | ||
|
||
create table "public"."waitlist" ( | ||
"id" bigint generated always as identity not null, | ||
"created_at" timestamp with time zone not null default now(), | ||
"email" citext not null | ||
); | ||
|
||
|
||
alter table "public"."waitlist" enable row level security; | ||
|
||
CREATE UNIQUE INDEX email_unique ON public.waitlist USING btree (email); | ||
|
||
CREATE UNIQUE INDEX waitlist_pk ON public.waitlist USING btree (id); | ||
|
||
alter table "public"."waitlist" add constraint "waitlist_pk" PRIMARY KEY using index "waitlist_pk"; | ||
|
||
alter table "public"."waitlist" add constraint "email_unique" UNIQUE using index "email_unique"; | ||
|
||
create policy "Enable insert for public" | ||
on "public"."waitlist" | ||
as permissive | ||
for insert | ||
to public | ||
with check (true); | ||
|
||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,29 +0,0 @@ | ||
-- Table: public.waitlist | ||
|
||
-- case insensitive column type | ||
CREATE EXTENSION IF NOT EXISTS citext; | ||
|
||
DROP TABLE IF EXISTS public.waitlist; | ||
CREATE TABLE IF NOT EXISTS public.waitlist | ||
( | ||
id int8 NOT NULL GENERATED ALWAYS AS IDENTITY, | ||
created_at timestamp with time zone NOT NULL DEFAULT now(), | ||
email citext NOT NULL, | ||
CONSTRAINT waitlist_pk PRIMARY KEY(id), | ||
CONSTRAINT email_unique UNIQUE(email) | ||
) TABLESPACE pg_default; | ||
|
||
ALTER TABLE IF EXISTS public.waitlist | ||
ENABLE ROW LEVEL SECURITY; | ||
|
||
GRANT ALL ON TABLE public.waitlist TO anon; | ||
GRANT ALL ON TABLE public.waitlist TO authenticated; | ||
GRANT ALL ON TABLE public.waitlist TO postgres; | ||
GRANT ALL ON TABLE public.waitlist TO service_role; | ||
GRANT ALL ON TABLE public.waitlist TO supabase_admin; | ||
|
||
DROP POLICY IF EXISTS "Enable insert for public" ON public.waitlist; | ||
CREATE POLICY "Enable insert for public" ON public.waitlist | ||
AS PERMISSIVE FOR INSERT | ||
TO public | ||
WITH CHECK (true); | ||
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
-- Table: public.waitlist | ||
|
||
-- case insensitive column type | ||
CREATE EXTENSION IF NOT EXISTS citext; | ||
|
||
DROP TABLE IF EXISTS public.waitlist; | ||
CREATE TABLE IF NOT EXISTS public.waitlist | ||
( | ||
id int8 NOT NULL GENERATED ALWAYS AS IDENTITY, | ||
created_at timestamp with time zone NOT NULL DEFAULT now(), | ||
email citext NOT NULL, | ||
CONSTRAINT waitlist_pk PRIMARY KEY(id), | ||
CONSTRAINT email_unique UNIQUE(email) | ||
) TABLESPACE pg_default; | ||
|
||
ALTER TABLE IF EXISTS public.waitlist | ||
ENABLE ROW LEVEL SECURITY; | ||
|
||
GRANT ALL ON TABLE public.waitlist TO anon; | ||
GRANT ALL ON TABLE public.waitlist TO authenticated; | ||
GRANT ALL ON TABLE public.waitlist TO postgres; | ||
GRANT ALL ON TABLE public.waitlist TO service_role; | ||
GRANT ALL ON TABLE public.waitlist TO supabase_admin; | ||
|
||
DROP POLICY IF EXISTS "Enable insert for public" ON public.waitlist; | ||
CREATE POLICY "Enable insert for public" ON public.waitlist | ||
AS PERMISSIVE FOR INSERT | ||
TO public | ||
WITH CHECK (true); |