diff --git a/.gitignore b/.gitignore index 315c565..0402771 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ target chat.db +chat.db* diff --git a/db.env b/db.env new file mode 100644 index 0000000..1cfdc43 --- /dev/null +++ b/db.env @@ -0,0 +1 @@ +export DATABASE_URL="sqlite:chat.db" diff --git a/migrations/0001_user_table.sql b/migrations/0001_user_table.sql new file mode 100644 index 0000000..4f89790 --- /dev/null +++ b/migrations/0001_user_table.sql @@ -0,0 +1,7 @@ +create table users ( + -- id INT NOT NULL AUTO_INCREMENT, + username VARCHAR NOT NULL UNIQUE, + password TEXT NOT NULL, + admin BOOLEAN NOT NULL DEFAULT FALSE, + PRIMARY KEY (username) +);