{"id":15467792,"url":"https://github.com/bradpotts/multi-tenancy-warden","last_synced_at":"2025-04-28T12:10:21.345Z","repository":{"id":26066516,"uuid":"29510188","full_name":"bradpotts/multi-tenancy-warden","owner":"bradpotts","description":"bare-bones alternative to mtdevise, adds basecamp style user logins for rails","archived":false,"fork":false,"pushed_at":"2022-04-11T22:39:20.000Z","size":289,"stargazers_count":9,"open_issues_count":10,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2024-10-21T23:02:14.771Z","etag":null,"topics":["authentication","bradpotts","engine","gem","multi-tenancy","multi-tenant","phcnetworks","rails","rails-engine","ruby","ruby-gem"],"latest_commit_sha":null,"homepage":"https://phcdevworks.com","language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/bradpotts.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"MIT-LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-01-20T03:38:00.000Z","updated_at":"2024-10-09T21:43:24.000Z","dependencies_parsed_at":"2022-08-20T13:10:51.045Z","dependency_job_id":null,"html_url":"https://github.com/bradpotts/multi-tenancy-warden","commit_stats":null,"previous_names":["phcnetworks/multi-tenancy-warden"],"tags_count":13,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bradpotts%2Fmulti-tenancy-warden","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bradpotts%2Fmulti-tenancy-warden/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bradpotts%2Fmulti-tenancy-warden/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bradpotts%2Fmulti-tenancy-warden/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bradpotts","download_url":"https://codeload.github.com/bradpotts/multi-tenancy-warden/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251122106,"owners_count":21539626,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["authentication","bradpotts","engine","gem","multi-tenancy","multi-tenant","phcnetworks","rails","rails-engine","ruby","ruby-gem"],"created_at":"2024-10-02T01:26:28.894Z","updated_at":"2025-04-28T12:10:21.329Z","avatar_url":"https://github.com/bradpotts.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![security](https://hakiri.io/github/PHCNetworks/multi-tenancy-warden/master.svg)](https://hakiri.io/github/PHCNetworks/multi-tenancy-warden/master)\n[![Code Climate](https://codeclimate.com/github/PHCNetworks/multi-tenancy-warden/badges/gpa.svg)](https://codeclimate.com/github/PHCNetworks/multi-tenancy-warden)\n[![Gem Version](https://badge.fury.io/rb/mtwarden.svg)](https://badge.fury.io/rb/mtwarden)\n[![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](https://github.com/PHCNetworks/multi-tenancy-warden/blob/master/MIT-LICENSE)\n\n### MTWarden Rails 5.1 Multi-Tenancy Engine Documentation  \nPHC MTWarden Rails 5.1 engine adds a separate multi-tenant layer that handles all user registrations, multi-tenancy app functions, and login through subdomains using Warden authentication gem.  \n\n#### Step 1 - Add Mtwarden to your gemfile and run command   \n\n\tgem 'mtwarden', '~\u003e 17.0'\n\tbundle exec install  \n\n#### Step 2 - Add and migrate mtwarden database tables  \n\n\trake railties:install:migrations  \n\trake db:migrate  \n\n#### Step 3 - Mount the Engine in your Routes File  \nAdd this line at the top of the routes.rb file.  \n\n\trequire 'mtwarden/constraints/subdomain_required'  \n\n#### Step 4 - Mount the Engine in your Routes File  \nAdd this line at the end of the routes.rb file.  \n\n\tmount Mtwarden::Engine, :at =\u003e '/'  \n\n#### Step 5 - Constrain the routes you want secured under multi-tenancy in your routes.rb file.\nAll the routes you want to have multi-tenancy login functions goes in between the constraints block.  \n\n\tconstraints(Mtwarden::Constraints::SubdomainRequired) do  \n\t\t# Routes Requiring Security \u0026 Multi-Tenancy Routes    \n\tend  \n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbradpotts%2Fmulti-tenancy-warden","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbradpotts%2Fmulti-tenancy-warden","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbradpotts%2Fmulti-tenancy-warden/lists"}