diff --git a/.gitignore b/.gitignore index f4401a3..eaacb21 100644 --- a/.gitignore +++ b/.gitignore @@ -6,3 +6,4 @@ node_modules .env .env.* !.env.example +server/.env diff --git a/server/.env b/server/.env index 7e0a02e..defdaff 100644 --- a/server/.env +++ b/server/.env @@ -8,7 +8,7 @@ ENVIRONMENT=dev PORT=8080 FRONTEND_URL="http://localhost:3000" -DATABASE_URL="file:./dev.db" +DATABASE_URL="file:./dev.sqlite" CLEANUP_INTERVAL_SECONDS=60 diff --git a/server/.env.example b/server/.env.example new file mode 100644 index 0000000..7e0a02e --- /dev/null +++ b/server/.env.example @@ -0,0 +1,18 @@ +# Environment variables declared in this file are automatically made available to Prisma. +# See the documentation for more detail: https://pris.ly/d/prisma-schema#accessing-environment-variables-from-the-schema + +# Prisma supports the native connection string format for PostgreSQL, MySQL, SQLite, SQL Server, MongoDB and CockroachDB. +# See the documentation for all the connection string options: https://pris.ly/d/connection-strings + +ENVIRONMENT=dev +PORT=8080 + +FRONTEND_URL="http://localhost:3000" +DATABASE_URL="file:./dev.db" + +CLEANUP_INTERVAL_SECONDS=60 + +POST_LIMIT_WINDOW_SECONDS=3 # 3 seconds +POST_LIMIT=1 +# POST_LIMIT_WINDOW=86400 # 24 hours +# POST_LIMIT=50 diff --git a/server/.gitignore b/server/.gitignore index b7dab5e..dd87e2d 100644 --- a/server/.gitignore +++ b/server/.gitignore @@ -1,2 +1,2 @@ node_modules -build \ No newline at end of file +build diff --git a/server/prisma/dev.db b/server/prisma/dev.db deleted file mode 100644 index 4b39e5a..0000000 Binary files a/server/prisma/dev.db and /dev/null differ