Sign in through GitHub

RailsCasts Pro episodes are now free!

Learn more or hide this

Multitenancy with Scopes

#388 Multitenancy with Scopes pro

Oct 20, 2012 | 12 minutes | Active Record, Authorization
A multi-tenant application can be difficult to implement because the data for each tenant must be completely separate. Here I show how to do this using subdomains and default scopes in Active Record.
  • Download:
  • source codeProject Files in Zip (71.8 KB)
  • mp4Full Size H.264 Video (25.9 MB)
  • m4vSmaller H.264 Video (12.8 MB)
  • webmFull Size VP8 Video (15.9 MB)
  • ogvFull Size Theora Video (28.3 MB)