Move jwt keys to database

Moved code for it to one place
Updated to chi v5
This commit is contained in:
Jamie Curnow
2023-05-26 14:50:41 +10:00
parent 29990110b1
commit ceb62fb0f2
12 changed files with 168 additions and 139 deletions

View File

@ -1,5 +1,15 @@
-- migrate:up
CREATE TABLE IF NOT EXISTS `keys`
(
id INTEGER PRIMARY KEY AUTOINCREMENT,
created_at INTEGER NOT NULL DEFAULT 0,
updated_at INTEGER NOT NULL DEFAULT 0,
is_deleted INTEGER NOT NULL DEFAULT 0,
public_key TEXT NOT NULL,
private_key TEXT NOT NULL
);
CREATE TABLE IF NOT EXISTS `user`
(
id INTEGER PRIMARY KEY AUTOINCREMENT,