Skip to content

Demo app I built to display information from a mock database depending on the subdomain. This basic concept can be used to implement multi-tenant architecture into any app.

License

Notifications You must be signed in to change notification settings

raymondkneipp/multi-tenant-via-subdomain

Repository files navigation

Contributors Forks Stargazers Issues MIT License LinkedIn


multi-tenant-via-subdomain

Demo app I built to display information from a mock database depending on the subdomain. This basic concept can be used to implement multi-tenant architecture into any app.
Explore the docs »

Report Bug · Request Feature

Table of Contents
  1. About The Project
  2. Getting Started
  3. Usage
  4. Contributing
  5. License
  6. Contact
  7. Acknowledgments

About The Project

Multi-Tenant Demo Screen Shot

(back to top)

Built With

(back to top)

Getting Started

For more information read my blog post about multi-tenant architecture. To get a local copy up and running follow these simple steps.

Prerequisites

  • Node.js
  • npm
    npm install npm@latest -g

Installation

  1. Clone the repo
    git clone https://github.com/raymondkneipp/multi-tenant-via-subdomain.git
  2. Install NPM packages
    npm install
  3. Start local server
    npm run dev

(back to top)

Usage

Visiting different subdomains will display different information from a mock database.

URL Results
http://localhost:3000 default page
http://rfkquery.localhost:3000 @rfkquery page
http://wesbos.localhost:3000 @wesbos page
http://stolinski.localhost:3000 @stolinski page
http://does.not.exist.localhost:3000 error page
http://does-not-exist.localhost:3000 error page

(back to top)

Resources

For more information about creating a multi-tenant app visit the following links

(back to top)

Contributing

Contributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.

If you have a suggestion that would make this better, please fork the repo and create a pull request. You can also simply open an issue with the tag "enhancement". Don't forget to give the project a star! Thanks again!

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/AmazingFeature)
  3. Commit your Changes (git commit -m 'Add some AmazingFeature')
  4. Push to the Branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

(back to top)

License

Distributed under the MIT License. See LICENSE.txt for more information.

(back to top)

Contact

Raymond Kneipp - @rfkquery - hello@raymondkneipp.com

Project Link: https://github.com/raymondkneipp/multi-tenant-via-subdomain

(back to top)

About

Demo app I built to display information from a mock database depending on the subdomain. This basic concept can be used to implement multi-tenant architecture into any app.

Topics

Resources

License

Stars

Watchers

Forks