feat: add global auth settings and pending users

This commit is contained in:
2026-07-02 06:27:32 -07:00
parent f6b7924d0c
commit 4bb4312b08
24 changed files with 2831 additions and 23 deletions

View File

@@ -0,0 +1,17 @@
CREATE TABLE "system_settings" (
"id" text PRIMARY KEY DEFAULT 'global' NOT NULL,
"registration_enabled" boolean DEFAULT true NOT NULL,
"oidc_enabled" boolean DEFAULT false NOT NULL,
"oidc_issuer_url" text DEFAULT '' NOT NULL,
"oidc_client_id" text DEFAULT '' NOT NULL,
"oidc_client_secret" text DEFAULT '' NOT NULL,
"oidc_scopes" text DEFAULT 'openid profile email' NOT NULL,
"oidc_redirect_uri" text DEFAULT '' NOT NULL,
"oidc_avatar_claim" text DEFAULT 'picture' NOT NULL,
"oidc_auto_provision" boolean DEFAULT false NOT NULL,
"created_at" timestamp with time zone DEFAULT now() NOT NULL,
"updated_at" timestamp with time zone DEFAULT now() NOT NULL
);
--> statement-breakpoint
ALTER TABLE "accounts" ADD COLUMN "avatar_url" text DEFAULT '' NOT NULL;--> statement-breakpoint
ALTER TABLE "organizations" ADD COLUMN "oidc_avatar_claim" text DEFAULT 'picture' NOT NULL;