|
|
@ -8,7 +8,7 @@ |
|
|
|
-- Table structure for table accesstokens |
|
|
|
-- Table structure for table accesstokens |
|
|
|
-- |
|
|
|
-- |
|
|
|
|
|
|
|
|
|
|
|
CREATE TABLE IF NOT EXISTS accesstokens ( |
|
|
|
CREATE TABLE IF NOT EXISTS `accesstokens` ( |
|
|
|
token TEXT NOT NULL PRIMARY KEY, |
|
|
|
token TEXT NOT NULL PRIMARY KEY, |
|
|
|
user_id INTEGER NOT NULL, |
|
|
|
user_id INTEGER NOT NULL, |
|
|
|
sudo INTEGER NOT NULL DEFAULT '0', |
|
|
|
sudo INTEGER NOT NULL DEFAULT '0', |
|
|
@ -24,7 +24,7 @@ CREATE TABLE IF NOT EXISTS accesstokens ( |
|
|
|
-- Table structure for table appcontent |
|
|
|
-- Table structure for table appcontent |
|
|
|
-- |
|
|
|
-- |
|
|
|
|
|
|
|
|
|
|
|
CREATE TABLE IF NOT EXISTS appcontent ( |
|
|
|
CREATE TABLE IF NOT EXISTS `appcontent` ( |
|
|
|
id TEXT NOT NULL PRIMARY KEY, |
|
|
|
id TEXT NOT NULL PRIMARY KEY, |
|
|
|
content TEXT NOT NULL, |
|
|
|
content TEXT NOT NULL, |
|
|
|
updated DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP |
|
|
|
updated DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP |
|
|
@ -36,7 +36,7 @@ CREATE TABLE IF NOT EXISTS appcontent ( |
|
|
|
-- Table structure for table collectionattributes |
|
|
|
-- Table structure for table collectionattributes |
|
|
|
-- |
|
|
|
-- |
|
|
|
|
|
|
|
|
|
|
|
CREATE TABLE IF NOT EXISTS collectionattributes ( |
|
|
|
CREATE TABLE IF NOT EXISTS `collectionattributes` ( |
|
|
|
collection_id INTEGER NOT NULL, |
|
|
|
collection_id INTEGER NOT NULL, |
|
|
|
attribute TEXT NOT NULL, |
|
|
|
attribute TEXT NOT NULL, |
|
|
|
value TEXT NOT NULL, |
|
|
|
value TEXT NOT NULL, |
|
|
@ -49,7 +49,7 @@ CREATE TABLE IF NOT EXISTS collectionattributes ( |
|
|
|
-- Table structure for table collectionkeys |
|
|
|
-- Table structure for table collectionkeys |
|
|
|
-- |
|
|
|
-- |
|
|
|
|
|
|
|
|
|
|
|
CREATE TABLE IF NOT EXISTS collectionkeys ( |
|
|
|
CREATE TABLE IF NOT EXISTS `collectionkeys` ( |
|
|
|
collection_id INTEGER PRIMARY KEY, |
|
|
|
collection_id INTEGER PRIMARY KEY, |
|
|
|
public_key blob NOT NULL, |
|
|
|
public_key blob NOT NULL, |
|
|
|
private_key blob NOT NULL |
|
|
|
private_key blob NOT NULL |
|
|
@ -61,7 +61,7 @@ CREATE TABLE IF NOT EXISTS collectionkeys ( |
|
|
|
-- Table structure for table collectionpasswords |
|
|
|
-- Table structure for table collectionpasswords |
|
|
|
-- |
|
|
|
-- |
|
|
|
|
|
|
|
|
|
|
|
CREATE TABLE IF NOT EXISTS collectionpasswords ( |
|
|
|
CREATE TABLE IF NOT EXISTS `collectionpasswords` ( |
|
|
|
collection_id INTEGER PRIMARY KEY, |
|
|
|
collection_id INTEGER PRIMARY KEY, |
|
|
|
password TEXT NOT NULL |
|
|
|
password TEXT NOT NULL |
|
|
|
); |
|
|
|
); |
|
|
@ -72,7 +72,7 @@ CREATE TABLE IF NOT EXISTS collectionpasswords ( |
|
|
|
-- Table structure for table collectionredirects |
|
|
|
-- Table structure for table collectionredirects |
|
|
|
-- |
|
|
|
-- |
|
|
|
|
|
|
|
|
|
|
|
CREATE TABLE IF NOT EXISTS collectionredirects ( |
|
|
|
CREATE TABLE IF NOT EXISTS `collectionredirects` ( |
|
|
|
prev_alias TEXT NOT NULL PRIMARY KEY, |
|
|
|
prev_alias TEXT NOT NULL PRIMARY KEY, |
|
|
|
new_alias TEXT NOT NULL |
|
|
|
new_alias TEXT NOT NULL |
|
|
|
); |
|
|
|
); |
|
|
@ -83,7 +83,7 @@ CREATE TABLE IF NOT EXISTS collectionredirects ( |
|
|
|
-- Table structure for table collections |
|
|
|
-- Table structure for table collections |
|
|
|
-- |
|
|
|
-- |
|
|
|
|
|
|
|
|
|
|
|
CREATE TABLE IF NOT EXISTS collections ( |
|
|
|
CREATE TABLE IF NOT EXISTS `collections` ( |
|
|
|
id INTEGER PRIMARY KEY AUTOINCREMENT, |
|
|
|
id INTEGER PRIMARY KEY AUTOINCREMENT, |
|
|
|
alias TEXT DEFAULT NULL UNIQUE, |
|
|
|
alias TEXT DEFAULT NULL UNIQUE, |
|
|
|
title TEXT NOT NULL, |
|
|
|
title TEXT NOT NULL, |
|
|
@ -102,7 +102,7 @@ CREATE TABLE IF NOT EXISTS collections ( |
|
|
|
-- Table structure for table posts |
|
|
|
-- Table structure for table posts |
|
|
|
-- |
|
|
|
-- |
|
|
|
|
|
|
|
|
|
|
|
CREATE TABLE IF NOT EXISTS posts ( |
|
|
|
CREATE TABLE IF NOT EXISTS `posts` ( |
|
|
|
id TEXT NOT NULL, |
|
|
|
id TEXT NOT NULL, |
|
|
|
slug TEXT DEFAULT NULL, |
|
|
|
slug TEXT DEFAULT NULL, |
|
|
|
modify_token TEXT DEFAULT NULL, |
|
|
|
modify_token TEXT DEFAULT NULL, |
|
|
@ -129,7 +129,7 @@ CREATE TABLE IF NOT EXISTS posts ( |
|
|
|
-- Table structure for table remotefollows |
|
|
|
-- Table structure for table remotefollows |
|
|
|
-- |
|
|
|
-- |
|
|
|
|
|
|
|
|
|
|
|
CREATE TABLE IF NOT EXISTS remotefollows ( |
|
|
|
CREATE TABLE IF NOT EXISTS `remotefollows` ( |
|
|
|
collection_id INTEGER NOT NULL, |
|
|
|
collection_id INTEGER NOT NULL, |
|
|
|
remote_user_id INTEGER NOT NULL, |
|
|
|
remote_user_id INTEGER NOT NULL, |
|
|
|
created DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP, |
|
|
|
created DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP, |
|
|
@ -142,7 +142,7 @@ CREATE TABLE IF NOT EXISTS remotefollows ( |
|
|
|
-- Table structure for table remoteuserkeys |
|
|
|
-- Table structure for table remoteuserkeys |
|
|
|
-- |
|
|
|
-- |
|
|
|
|
|
|
|
|
|
|
|
CREATE TABLE IF NOT EXISTS remoteuserkeys ( |
|
|
|
CREATE TABLE IF NOT EXISTS `remoteuserkeys` ( |
|
|
|
id TEXT NOT NULL, |
|
|
|
id TEXT NOT NULL, |
|
|
|
remote_user_id INTEGER NOT NULL, |
|
|
|
remote_user_id INTEGER NOT NULL, |
|
|
|
public_key blob NOT NULL, |
|
|
|
public_key blob NOT NULL, |
|
|
@ -155,7 +155,7 @@ CREATE TABLE IF NOT EXISTS remoteuserkeys ( |
|
|
|
-- Table structure for table remoteusers |
|
|
|
-- Table structure for table remoteusers |
|
|
|
-- |
|
|
|
-- |
|
|
|
|
|
|
|
|
|
|
|
CREATE TABLE IF NOT EXISTS remoteusers ( |
|
|
|
CREATE TABLE IF NOT EXISTS `remoteusers` ( |
|
|
|
id INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT, |
|
|
|
id INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT, |
|
|
|
actor_id TEXT NOT NULL, |
|
|
|
actor_id TEXT NOT NULL, |
|
|
|
inbox TEXT NOT NULL, |
|
|
|
inbox TEXT NOT NULL, |
|
|
@ -169,7 +169,7 @@ CREATE TABLE IF NOT EXISTS remoteusers ( |
|
|
|
-- Table structure for table userattributes |
|
|
|
-- Table structure for table userattributes |
|
|
|
-- |
|
|
|
-- |
|
|
|
|
|
|
|
|
|
|
|
CREATE TABLE IF NOT EXISTS userattributes ( |
|
|
|
CREATE TABLE IF NOT EXISTS `userattributes` ( |
|
|
|
user_id INTEGER NOT NULL, |
|
|
|
user_id INTEGER NOT NULL, |
|
|
|
attribute TEXT NOT NULL, |
|
|
|
attribute TEXT NOT NULL, |
|
|
|
value TEXT NOT NULL, |
|
|
|
value TEXT NOT NULL, |
|
|
@ -182,7 +182,7 @@ CREATE TABLE IF NOT EXISTS userattributes ( |
|
|
|
-- Table structure for table users |
|
|
|
-- Table structure for table users |
|
|
|
-- |
|
|
|
-- |
|
|
|
|
|
|
|
|
|
|
|
CREATE TABLE IF NOT EXISTS users ( |
|
|
|
CREATE TABLE IF NOT EXISTS `users` ( |
|
|
|
id INTEGER PRIMARY KEY AUTOINCREMENT, |
|
|
|
id INTEGER PRIMARY KEY AUTOINCREMENT, |
|
|
|
username TEXT NOT NULL UNIQUE, |
|
|
|
username TEXT NOT NULL UNIQUE, |
|
|
|
password TEXT NOT NULL, |
|
|
|
password TEXT NOT NULL, |
|
|
|