Skip to content

Latest commit

History

History

apollo

Folders and files

NameName
Last commit message
Last commit date

parent directory

..

Apollo example for Prisma-multi-tenant

This is an example project to run Apollo with multi-tenancy using Prisma-multi-tenant. (See also the tutorial "Adding multi-tenancy to your Apollo app")

Installation

npm install

Start the server, and go to http://localhost:4000

npm run start

Then, go to src/multi-tenant.js, and change the tenant name to "prod":

const name = 'prod'

Finally, re-start the server, and refresh the page!

Commands you can try

This will list the available tenants:

pmt list # or prisma-multi-tenant list

This will open studio for the tenants (dev & prod):

pmt studio dev
pmt studio prod

This will make you create a new tenant:

pmt new