A governance portal for submitting, reviewing, and tracking Cardano Amendment Proposals (CAPs) and Cardano Improvement Standards (CISs). Wallet authentication via CIP-30, role-based editorial workflow, public read API.
| Layer | Technology |
|---|---|
| Backend | Python · FastAPI · SQLAlchemy · PostgreSQL |
| Frontend | Vanilla JS · nginx |
| Auth | Cardano CIP-30 wallet (Eternl, Vespr, Lace, …) |
| Deployment | Docker Compose |
The portal ships as three Docker services: backend (FastAPI), frontend (nginx), and backup (scheduled PostgreSQL dumps). A docker-compose.yml is included for running everything on a single host.
- Docker and Docker Compose
- A Cardano mainnet wallet extension installed in your browser
cp .env.example .envEdit .env and set at minimum:
POSTGRES_PASSWORD=<long random string>
JWT_SECRET=<long random string>Generate secrets with openssl rand -hex 32.
docker compose up -dThe portal is available at http://localhost.
Put a reverse proxy such as Caddy or nginx in front of the stack to terminate TLS and serve the portal over HTTPS. Point it at http://localhost:80.
Add SMTP credentials to .env:
SMTP_HOST=smtp.example.com
SMTP_PORT=587
SMTP_USERNAME=<username>
SMTP_PASSWORD=<password>
SMTP_FROM=noreply@yourdomain.com
APP_URL=https://your-domain.comAny SMTP provider works. Leave these blank to disable email notifications.
| Variable | Required | Description |
|---|---|---|
POSTGRES_PASSWORD |
Yes | PostgreSQL password |
JWT_SECRET |
Yes | JWT signing secret |
SMTP_HOST |
No | SMTP server hostname |
SMTP_PORT |
No | SMTP port (default: 587) |
SMTP_USERNAME |
No | SMTP username |
SMTP_PASSWORD |
No | SMTP password |
SMTP_FROM |
No | Sender address for notifications |
APP_URL |
No | Public URL of the portal (used in email links) |
BACKUP_RETAIN_DAYS |
No | Days of backup files to keep (default: 7) |
All read endpoints are public and require no authentication.
Write operations require a Cardano wallet JWT:
GET /auth/challenge— fetch a one-time challenge string- Sign it with
cardano.signData(CIP-30) POST /auth/verify— submit the signature, receive a Bearer token- Pass
Authorization: Bearer <token>on authenticated requests
Interactive documentation is available at /docs on the backend service.
| Role | Capabilities |
|---|---|
| User | Submit proposals, comment, follow proposals |
| Editor | Apply lifecycle labels, suggest edits to proposals |
| Admin | Manage editor and admin roles |
Roles are assigned by an existing admin via the portal's admin panel.
# Backend
cd backend
python -m venv .venv && source .venv/bin/activate
pip install -r requirements.txt
uvicorn main:app --reload
# Frontend — static files, no build step required
# Open frontend/index.html or serve with any static file serverThe backend defaults to SQLite (cap.db) when DATABASE_URL is not set.