A Django app to allow multi-tenancy.
Project description
django-omnitenant
django-omnitenant is a Django app that enables multi-tenancy with DB-level isolation and schema-level isolation.
Detailed documentation is in the "docs" directory.
Quick start
- Add "django_omnitenant" to your
INSTALLED_APPSsetting like this:
INSTALLED_APPS = [
...,
"django_omnitenant",
]
**Note:** Place django_omnitenant at the last in installed apps so that it will reregister all the default only apps to show on default db
**Note:** Make sure `DEFAULT_TENANT_NAME` is postgre schema name complaint
**Note:** Need to set the `DEFAULT_HOST`
### Test
For tests's tenant setup you can override _setup_tenant method to setup tenant but make sure to assign it to the class variable cls.tenant
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
django_omnitenant-0.2.1.tar.gz
(21.2 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file django_omnitenant-0.2.1.tar.gz.
File metadata
- Download URL: django_omnitenant-0.2.1.tar.gz
- Upload date:
- Size: 21.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
884d419c2d540a4eb8372aff7107cd31b975f24b656f8db7476b68abbbf69370
|
|
| MD5 |
43eecffe146ed24860c9ad9ecd6b0fd2
|
|
| BLAKE2b-256 |
d04550b7ae9c6e713ff0915d148682917fb45c1ba68454ad25ef7bb3a632729d
|
File details
Details for the file django_omnitenant-0.2.1-py3-none-any.whl.
File metadata
- Download URL: django_omnitenant-0.2.1-py3-none-any.whl
- Upload date:
- Size: 31.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5869baed2cba2d50e137e5dfa76457cae71124cc5d013dcf3e57abb7c9d30bc9
|
|
| MD5 |
71a51967a9bbf71b931e9081cf79146d
|
|
| BLAKE2b-256 |
c9e6a5f4cd7381c66a4810af24792cb0d3dc9239c7701a5ab93cbe1b5bc06bbc
|