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.6.4
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.6.4.tar.gz | 21.8 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| gisweb_tenants-0.6.4-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 49.8 kB
Release files / gisweb_tenants-0.6.4.tar.gz
| Download URL | gisweb_tenants-0.6.4.tar.gz |
|---|---|
| Size | 21.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
def748206c1ca86949d56b76ff2e0fa67808cffcad5ae9f7409211d5d83df41b
|
|
BLAKE2b-256 checksum How to use checksums |
0689158cfd1eb085e19e117d1a33e48de34fe9c359e5309ea6dbc97fb8bf3c3a
|
| 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-136-generic
|
Release files / gisweb_tenants-0.6.4-py3-none-any.whl
| Download URL | gisweb_tenants-0.6.4-py3-none-any.whl |
|---|---|
| Size | 28.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
0f07875104a054f3e4885ff4262894ee5cb401badd288ec7f404a066c6475c64
|
|
BLAKE2b-256 checksum How to use checksums |
dd84c1cca05707545078540b267408a95f99b15626d0226f27ba43c092c7db51
|
| 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-136-generic
|