Home

Awesome

README

SaaS (organisations can have many members; organisation is billed)

haml devise simple_form https://github.com/scambra/devise_invitable

  1. Basic multitenant +

1.1. Users

1.2. Tenants

1.2. devise_invitable - new user, new member +

1.3. devise_invitable - new user, resend invitation +

1.3. OPTIONAL: member of a tenant can exist without user?

1.4. subdomains

1.2. acts_as_tenant Current_tenant is set by session/subdomain. Members are scoped by current_tenant. All models except User and Tenant are scoped by current_tenant.

Alternative Easy way (no subdomains)

  1. Billing
  1. Roles Roles are scoped by tenant. When a user creates a tenant, he becomes the tenant admin. Admin:
  1. ransack, public_activity, friendly_id

find tenant by subdomain https://medium.com/@praaveen/multi-tenancy-and-sub-domain-lvh-with-rails-f364c9dc0566