summaryrefslogtreecommitdiffstats
path: root/src/db/server.sql
diff options
context:
space:
mode:
authorsadbeast <sadbeast@sadbeast.com>2024-07-16 18:16:29 -0700
committersadbeast <sadbeast@sadbeast.com>2024-10-05 16:40:55 -0700
commit6bd24af2ffbea91db1b10a5d5258980ce2068c7f (patch)
tree66634833f2d45260be5fcaf9111400eda12f03cc /src/db/server.sql
downloadteamdraft-main.tar.gz
teamdraft-main.tar.bz2
let's goHEADmain
Diffstat (limited to 'src/db/server.sql')
-rw-r--r--src/db/server.sql13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/db/server.sql b/src/db/server.sql
new file mode 100644
index 0000000..66410a9
--- /dev/null
+++ b/src/db/server.sql
@@ -0,0 +1,13 @@
+-- this should only be needed per postgresql instance
+
+-- can modify the database schema
+DROP ROLE IF EXISTS ddl;
+CREATE ROLE ddl WITH NOLOGIN;
+
+-- can modify database data
+DROP ROLE IF EXISTS dml;
+CREATE ROLE dml WITH NOLOGIN;
+
+-- can only read database data
+DROP ROLE IF EXISTS read_only;
+CREATE ROLE read_only WITH NOLOGIN;