gisweb-tenants
Libreria Python per gestire configurazione multitenant in applicazioni FastAPI.
Obiettivo
Separare:
- configurazione pubblica per tenant
- configurazione sensibile per tenant (Docker secrets)
e restituire un unico oggetto validato e tipizzato.
Convenzioni
Config pubblica
Directory configurabile, ad esempio:
./config/tenant_rapallo.json
Example Package
This is a simple example package. You can use to write your content.
poetry update poetry build poetry publish
casini venv per attivare quello giusto: source $(poetry env info --path)/bin/activate
poetry env info -p
rm -rf poetry env info -p
poetry env use python
Esempio:
{
"tenant": "rapallo",
"comune": {
"nome": "Comune di Rapallo"
},
"db": {},
"keycloak": {
"realm": "rapallo",
"client_id": "backend"
},
"paths": {
"upload_dir": "/data/rapallo/uploads",
"template_dir": "/data/rapallo/templates"
}
}
Metadata
Release files for gisweb-tenants 1.0.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| gisweb_tenants-1.0.0.tar.gz | 24.2 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| gisweb_tenants-1.0.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 54.4 kB
Release files / gisweb_tenants-1.0.0.tar.gz
| Download URL | gisweb_tenants-1.0.0.tar.gz |
|---|---|
| Size | 24.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
cc927aee24769d12adf3589e53af8caac4439d8fbef36036d9f3e7c293c445ce
|
|
BLAKE2b-256 checksum How to use checksums |
a67e376873b311bc3132f77e69823695619b929d7452e226181bb5cb18be9b0e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/2.1.3 CPython/3.10.12 Linux/6.8.0-139-generic
|
Release files / gisweb_tenants-1.0.0-py3-none-any.whl
| Download URL | gisweb_tenants-1.0.0-py3-none-any.whl |
|---|---|
| Size | 30.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
d351f843c463d5ae26a55461c92f49e928b972af726117e5491f1fde6c6a414f
|
|
BLAKE2b-256 checksum How to use checksums |
f5d7db439c1faa0ea0e5d16e913de95ae6ac97c48550072b0541158ed6e71d1a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/2.1.3 CPython/3.10.12 Linux/6.8.0-139-generic
|