https://github.com/amssdias/multitenant-blog-platform
A web where users can create their own blog with their own subdomain and manage their posts
https://github.com/amssdias/multitenant-blog-platform
django multitenant postgres redis schema
Last synced: 2 months ago
JSON representation
A web where users can create their own blog with their own subdomain and manage their posts
- Host: GitHub
- URL: https://github.com/amssdias/multitenant-blog-platform
- Owner: amssdias
- Created: 2025-03-20T14:35:14.000Z (2 months ago)
- Default Branch: master
- Last Pushed: 2025-03-20T22:16:32.000Z (2 months ago)
- Last Synced: 2025-03-20T22:26:14.521Z (2 months ago)
- Topics: django, multitenant, postgres, redis, schema
- Language: Python
- Homepage:
- Size: 54.7 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Django Multitenant Blog Platform




## 🚀 About the Project
This is a **Django Multitenant Blog Platform** where users can sign up on the **main domain**, and upon registration,
they get their own **subdomain** with an isolated schema to create and manage their own blog.## 🔥 Features
- **Main Domain** (`example.com`)
- Users can **sign up** or **log in**.
- Upon signup, users get a **dedicated subdomain** (`user.example.com`).
- **Subdomains** (`user.example.com`)
- Users are redirected here upon login.
- Create, edit, and manage blog posts.
- Each tenant has an **isolated database schema**.
- **Tech Stack**
- Django with **Multitenancy**
- PostgreSQL as the database
- Redis for caching and session management
- Docker support (optional)## 🛠️ Installation & Setup
### 1️⃣ Clone the Repository
```sh
git clone https://github.com/yourusername/multitenant-blog.git
cd multitenant-blog
```### 2️⃣ Install Dependencies
```sh
pip install -r requirements.txt
```### 3️⃣ Configure the Environment
Create a `.env` file and set up your database and Redis connections.
### 4️⃣ Run Migrations
```sh
python manage.py migrate
```### 5️⃣ Start the Development Server
```sh
python manage.py runserver dev.localhost.com:8000
```Ensure you have added `dev.localhost.com` and any test subdomains (`blog1.localhost.com`, `blog2.localhost.com`) to your
**hosts file**.## 🎯 How It Works
1. **User signs up on the main domain**.
2. **A new subdomain and schema are created**.
3. **User is redirected to their subdomain** upon login.
4. **User can create and manage blog posts** from their subdomain.---
🚀 Happy Coding! 🎯