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.4.0.tar.gz (16.6 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.4.0-py3-none-any.whl (22.0 kB view details)

Uploaded Python 3

File details

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

File metadata

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

File hashes

Hashes for gisweb_tenants-0.4.0.tar.gz
Algorithm Hash digest
SHA256 62e71fada5b6f33cb9233924ac9103db47f6895f56002832d009cf0e70c31f4b
MD5 00cc6e6e89236d5a2c8b8deba1718311
BLAKE2b-256 fad0a88232b2324e7ea39d952736d5657b1cec87e56769e872df51d83906117c

See more details on using hashes here.

File details

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

File metadata

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

File hashes

Hashes for gisweb_tenants-0.4.0-py3-none-any.whl
Algorithm Hash digest
SHA256 3341ae0999ce9273b369fab0ffa32e6fc11d89b8d0a2e07275e91a0140cd3624
MD5 66050102d10054d3b1991cdc8ff15111
BLAKE2b-256 4bf99ffbfedd714c337deed2e832a66cf8f9cf084204cecb5ab6b3f1678a6751

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