Skip to main content

Public registration form, operator review dashboard, and Keycloak provisioning hooks for the TAMIS dataspace.

Project description

djangoldp_tamis_onboarding

Public registration form, operator review dashboard, and Keycloak provisioning hooks for the TAMIS dataspace.

What's in here

  • RegisterParticipant model — mirrors the MediaEnterpriseCredential VC claim shape (organisation, legal address, sectoral roles, general + billing contacts) plus a state-machine lifecycle (pending → processing → approved | rejected).
  • ParticipantAttachment model — one row per supporting document (K-bis, VAT cert, PROCIREP/ISAN proofs, etc.); files land in a private storage tree scoped per participant.
  • Public multi-step registration form (/registration/) + success page.
  • Operator dashboard (/registration/admin/) — Django-side approve / deny flow.
  • Keycloak provisioning stub (keycloak_service.py) + background provisioning task (tasks.py) triggered on processing.
  • Email templates for admin notifications, rejection, and welcome.
  • ./manage.py generate_sample_documents — plausible random supporting documents for demos and testing.

Requirements

  • Python ≥ 3.10, Django 5.2, DjangoLDP 5.0
  • Pillow (logo re-encoding and sample-doc rendering)
  • python-magic + system libmagic1 (content-based MIME sniffing on uploads)
  • setuptools<80 in the host environment — DjangoLDP still imports pkg_resources, which setuptools 80+ deprecates at import time (setuptools' own warning message says "<81" but the deprecation shipped in 80.x). Pin it in your image with pip install 'setuptools<80' before installing this package.

Install

pip install djangoldp-tamis-onboarding

Add to your DjangoLDP settings.yml:

dependencies:
  - djangoldp-tamis-onboarding

ldppackages:
  - djangoldp_tamis_onboarding

Then wire the URLs under your onboarding prefix (default onboarding/):

path("onboarding/", include("djangoldp_tamis_onboarding.urls")),

Configuration

Settings read by the package (all optional except TAMIS_ADMIN_MAILS):

Setting Purpose
TAMIS_ADMIN_MAILS List of operator emails notified on each new submission.
ONBOARDING_PREFIX URL prefix the host mounts the app under (default "").
ONBOARDING_HOMEPAGE_URL, ONBOARDING_DOCUMENTATION_URL, ONBOARDING_SUPPORT_EMAIL Links shown on the success page.
TAMIS_ONBOARDING_PRIVATE_MEDIA_ROOT Directory for attachment bytes, kept outside MEDIA_ROOT so nginx can't serve them directly. Defaults to <MEDIA_ROOT>-private/.
TAMIS_ONBOARDING_USE_XACCEL When True, the operator download view emits X-Accel-Redirect instead of streaming the file. Requires an internal; nginx location /internal-attachments/ block mapped to TAMIS_ONBOARDING_PRIVATE_MEDIA_ROOT.
KEYCLOAK_BASE_URL, KEYCLOAK_REALM, KEYCLOAK_CLIENT_ID, KEYCLOAK_CLIENT_SECRET Read by keycloak_service.py (stubbed in Phase 1).

Runnable stack

The governance-services/ docker-compose stack in the TAMIS workspace bundles this package with Keycloak + Postgres + nginx for local and staging onboarding.

Sample documents

Generate plausible K-bis, VAT certificates, PROCIREP/ISAN membership proofs for manual testing:

./manage.py generate_sample_documents --output ./sample-docs --count 3 --format both

License

MIT.

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

djangoldp_tamis_onboarding-1.0.4.tar.gz (40.9 kB view details)

Uploaded Source

Built Distribution

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

djangoldp_tamis_onboarding-1.0.4-py3-none-any.whl (54.3 kB view details)

Uploaded Python 3

File details

Details for the file djangoldp_tamis_onboarding-1.0.4.tar.gz.

File metadata

  • Download URL: djangoldp_tamis_onboarding-1.0.4.tar.gz
  • Upload date:
  • Size: 40.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.12.1.2 readme-renderer/45.0 requests/2.34.2 requests-toolbelt/1.0.0 urllib3/2.7.0 tqdm/4.68.4 importlib-metadata/9.0.0 keyring/25.7.0 rfc3986/2.0.0 colorama/0.4.6 CPython/3.11.15

File hashes

Hashes for djangoldp_tamis_onboarding-1.0.4.tar.gz
Algorithm Hash digest
SHA256 41fa3596b298b3faaa9c7e167d295ea747ffb0e2613a2b67e8dcdbcfdf21676e
MD5 1c0867bc86022ea4d0cc30b89ab5defc
BLAKE2b-256 b801d9dcd1a0b2d6825ba0f94c6b027a7b88f224be804317b563a942ed2a745a

See more details on using hashes here.

File details

Details for the file djangoldp_tamis_onboarding-1.0.4-py3-none-any.whl.

File metadata

  • Download URL: djangoldp_tamis_onboarding-1.0.4-py3-none-any.whl
  • Upload date:
  • Size: 54.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.12.1.2 readme-renderer/45.0 requests/2.34.2 requests-toolbelt/1.0.0 urllib3/2.7.0 tqdm/4.68.4 importlib-metadata/9.0.0 keyring/25.7.0 rfc3986/2.0.0 colorama/0.4.6 CPython/3.11.15

File hashes

Hashes for djangoldp_tamis_onboarding-1.0.4-py3-none-any.whl
Algorithm Hash digest
SHA256 75e1f8900dec908d04b6d9f6eaac9b1b32df2bd855904e7e9b5e9e638e7fbe96
MD5 f5452d1870d457653a505a294315fec1
BLAKE2b-256 73b357364fd8cdf11bc97a80bbe9f0a37d4a428b79719f5c271a78ad9d2dcbef

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