Skip to main content

Gestione multi tenant db e oidc

Project description

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"
  }
}

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

gisweb_tenants-0.5.0.tar.gz (17.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

gisweb_tenants-0.5.0-py3-none-any.whl (23.4 kB view details)

Uploaded Python 3

File details

Details for the file gisweb_tenants-0.5.0.tar.gz.

File metadata

  • Download URL: gisweb_tenants-0.5.0.tar.gz
  • Upload date:
  • Size: 17.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.1.3 CPython/3.10.12 Linux/6.8.0-117-generic

File hashes

Hashes for gisweb_tenants-0.5.0.tar.gz
Algorithm Hash digest
SHA256 eaf71ef3ac668133ce93ee530dc400fdd44a87cdb7f76238a0ac496fa0842150
MD5 e80695ed9b9d1ded87507cac99fabe07
BLAKE2b-256 53eda4435fca84beda007c8d9f27f167604339874822c17a35156e9d2feebb26

See more details on using hashes here.

File details

Details for the file gisweb_tenants-0.5.0-py3-none-any.whl.

File metadata

  • Download URL: gisweb_tenants-0.5.0-py3-none-any.whl
  • Upload date:
  • Size: 23.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.1.3 CPython/3.10.12 Linux/6.8.0-117-generic

File hashes

Hashes for gisweb_tenants-0.5.0-py3-none-any.whl
Algorithm Hash digest
SHA256 9d473807f4ec115a12617d770ca81bf97b7b625340996c93ccef13e17314d199
MD5 6f9f673187f9f2a89972431ebe92615a
BLAKE2b-256 348ba7d9d2e0b8bbf1d0221fb5728391b7ee65479ac45730cc5b5ddada10daed

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page