Skip to content
This repository has been archived by the owner on Jul 10, 2024. It is now read-only.

Special deployment considerations needed? #55

Closed
thuringia opened this issue Sep 1, 2020 · 1 comment
Closed

Special deployment considerations needed? #55

thuringia opened this issue Sep 1, 2020 · 1 comment

Comments

@thuringia
Copy link

Thank you for creating a plugin for blitz-js, this makes my current project much easier!

What I did not understand from the docs, or the PRs, is how an application deployment with prisma-multi-tenant works.
For example, the docs for blitz feature Vercel and Render, however Render only gives you one "database" (which looks like the result of CREATE DATABASE) per instance of their paid offering.

What I'm wondering now is, how does PMT implement tenancy exactly regarding this?
Is each "database" in PMT an actual (Postgres) DB, meaning I need to deploy either multiple nodes, or services if managed. Or is it using some kind of schema modifications to implement tenancy inside one instance of a postgres DB?

Sorry if this has been asked before, especially given the existance of #31 and #40

Thanks for your hard work!

@Errorname
Copy link
Owner

Hi @thuringia 👋

Thanks for the question. The current architecture of prisma-multi-tenant is indeed based on the "one tenant = one database" model, as well as another database for the "management" of your tenants. This means that you would indeed need to have multiple databases. (I don't know Render, but it does look like you can only have one database indeed)

However, as you pointed out, once #40 is implemented, you will be able to use prisma-multi-tenant with a "one database = multiple tenants" model, which would let you deploy on a single database. (I haven't had a lot of time this past couple month to work on pmt, I'll try to find more time in the next couple weeks 😄 )

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants