Skip to content

Multi-Tenancy is a sample rails application using apartment gem

Notifications You must be signed in to change notification settings

iwilliam317/multi-tenancy

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Multi-Tenancy

This small repository was created to reproduce an example of usage of apartment gem. It has two models (User and Project) to show how multi-tenancy actually works.

Testing

  • start installing all the dependencies bundle

  • raise the server rails server

  • let's use lvh.me so it will allow to test subdomains locally. *lvh simulates localhost lvh.me:3000/users.

  • in order to see the differences create two users.

  • then use the subdomain. Eg: subdomain.lvh:3000/projects.

  • create a project and then switch to another user domain there will be only the respective projects, because apartment gem automatically separate tables from each tenant.

it's great \o/

About

Multi-Tenancy is a sample rails application using apartment gem

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published