mirror of
https://github.com/openziti/zrok.git
synced 2025-02-06 21:39:39 +01:00
fine, sqlite, fine... (#96)
This commit is contained in:
parent
4e4bd1c876
commit
e8e87ca6ac
@ -1,22 +1,3 @@
|
||||
-- +migrate Up
|
||||
|
||||
alter table accounts rename to accounts_old;
|
||||
|
||||
create table accounts (
|
||||
id integer primary key,
|
||||
email string not null unique,
|
||||
password string not null,
|
||||
token string not null unique,
|
||||
limitless boolean not null default(false),
|
||||
created_at datetime not null default(strftime('%Y-%m-%d %H:%M:%f', 'now')),
|
||||
updated_at datetime not null default(strftime('%Y-%m-%d %H:%M:%f', 'now')),
|
||||
|
||||
constraint chk_email check (email <> ''),
|
||||
constraint chk_password check (password <> ''),
|
||||
constraint chk_token check(token <> '')
|
||||
);
|
||||
|
||||
insert into accounts (id, email, password, token, created_at, updated_at)
|
||||
select id, email, password, token, created_at, updated_at from accounts_old;
|
||||
|
||||
drop table accounts_old;
|
||||
alter table accounts add column limitless boolean not null default(false);
|
Loading…
Reference in New Issue
Block a user