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 0.9.1
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-0.9.1.tar.gz | 23.8 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| gisweb_tenants-0.9.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 53.7 kB
Release files / gisweb_tenants-0.9.1.tar.gz
| Download URL | gisweb_tenants-0.9.1.tar.gz |
|---|---|
| Size | 23.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
9aac84baa6c6363014e8561fd1e39e4533b7229a46a6601d444f0182fbe5057b
|
|
BLAKE2b-256 checksum How to use checksums |
98b746c4d6e23d255df6b2e81c0b39258557c809146efd466310863a6e14bf72
|
| 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-0.9.1-py3-none-any.whl
| Download URL | gisweb_tenants-0.9.1-py3-none-any.whl |
|---|---|
| Size | 29.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
3b8cd1386b9a5105a172a715435f0ce93db48406e0220c7a1ef1a25a6e77daa9
|
|
BLAKE2b-256 checksum How to use checksums |
356e17571f6e0d4e035841ab758f24848628233a97f7f3bb3a1e55e490842747
|
| 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
|