From 294d06ea4865e4bae88c1dee6a8a841a7f204189 Mon Sep 17 00:00:00 2001
From: Runxi Yu <me@runxiyu.org>
Date: Wed, 19 Feb 2025 20:44:54 +0800
Subject: ssh/recv, users, schema: Create pubkey_only users

---
 schema.sql | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

(limited to 'schema.sql')

diff --git a/schema.sql b/schema.sql
index 2589a07..3db8967 100644
--- a/schema.sql
+++ b/schema.sql
@@ -48,7 +48,8 @@ CREATE TABLE mailing_list_emails (
 
 CREATE TABLE users (
 	id INTEGER GENERATED ALWAYS AS IDENTITY PRIMARY KEY,
-	username TEXT NOT NULL UNIQUE,
+	username TEXT UNIQUE,
+	type TEXT NOT NULL CHECK (type IN ('pubkey_only', 'registered')),
 	password TEXT
 );
 
-- 
cgit v1.2.3

