refactor to db setup for admin-cli
This commit is contained in:
1 parent
747442799d
commit
5b48288179
4 files changed
+22
No files matched your search
@@ -0,0 +1,2 @@
|
||||
DROP DATABASE IF EXISTS bubble;
|
||||
CREATE DATABASE bubble;
|
||||
File renamed without changes.
@@ -0,0 +1,8 @@
|
||||
-- Create the user that we'll use for service data
|
||||
DO $SERVICE_USER_CREATION$
|
||||
BEGIN
|
||||
CREATE ROLE bubble_api;
|
||||
EXCEPTION WHEN duplicate_object THEN RAISE NOTICE '%, skipping', SQLERRM USING ERRCODE = SQLSTATE;
|
||||
END
|
||||
$SERVICE_USER_CREATION$;
|
||||
|
||||
@@ -0,0 +1,12 @@
|
||||
CREATE TABLE IF NOT EXISTS users (
|
||||
id INTEGER,
|
||||
name VARCHAR(256),
|
||||
PRIMARY KEY (id)
|
||||
);
|
||||
|
||||
|
||||
CREATE TABLE IF NOT EXISTS invites (
|
||||
id BIGINT,
|
||||
expires INTEGER,
|
||||
PRIMARY KEY (id)
|
||||
);
|
||||
Reference in new issue
Block a user