Boilerplate
This commit is contained in:
parent
9001204c9e
commit
5ed1bfc2cc
3 changed files with 29 additions and 0 deletions
5
.gitignore
vendored
Normal file
5
.gitignore
vendored
Normal file
|
@ -0,0 +1,5 @@
|
|||
.idea/
|
||||
config.json
|
||||
syntax:glob
|
||||
**.pyc
|
||||
|
8
config.sample.json
Normal file
8
config.sample.json
Normal file
|
@ -0,0 +1,8 @@
|
|||
/*
|
||||
create a db_config.json here's
|
||||
*/
|
||||
{
|
||||
"config":{
|
||||
"db_params":{"uri":"postgresql://user:password@host:port/dbname"}
|
||||
}
|
||||
}
|
16
scripts/db/postgresql/schema.sql
Normal file
16
scripts/db/postgresql/schema.sql
Normal file
|
@ -0,0 +1,16 @@
|
|||
create type user_role as enum ('USER','ADMIN','EDITOR');
|
||||
|
||||
create table users(
|
||||
id serial primary key,
|
||||
username text unique not null,
|
||||
name text,
|
||||
surname text,
|
||||
email text,
|
||||
createts timestamptz not null default now(),
|
||||
password text,
|
||||
salt text,
|
||||
updatets timestamptz not null default now(),
|
||||
role_list user_role[] not null default ARRAY['USER'::user_role],
|
||||
user_data jsonb
|
||||
);
|
||||
|
Loading…
Reference in a new issue