Local Docker services:
postgresclickhousebackendfrontend
Start the production-style local stack:
docker compose up --build -dStart the development stack with backend reload and the Vite dev server:
docker compose -f docker-compose.yml -f docker-compose.dev.yml up --build -dStop everything:
docker compose downFull reset:
docker compose down -v
docker compose -f docker-compose.yml -f docker-compose.dev.yml up --build -dcd backend
python -m venv .venv
. .venv/bin/activate
pip install -r requirements.txt
uvicorn app.main:app --reload --host 0.0.0.0 --port 8000Run tests:
backend/.venv/bin/python -m pytestcd frontend
npm install
npm run devRun checks:
cd frontend
npm run tsc
npm run lint
npm test
npm run buildThe frontend is the only Node package in the repository. Run npm commands from frontend/.
| Variable | Purpose |
|---|---|
POSTGRES_HOST |
Postgres hostname |
POSTGRES_PORT |
Postgres port |
POSTGRES_DB |
Postgres database |
POSTGRES_USER |
Postgres user |
POSTGRES_PASSWORD |
Postgres password |
CLICKHOUSE_HOST |
ClickHouse hostname |
CLICKHOUSE_HTTP_PORT |
ClickHouse HTTP port used by the backend |
CLICKHOUSE_DATABASE |
ClickHouse database |
CLICKHOUSE_USER |
ClickHouse user |
CLICKHOUSE_PASSWORD |
ClickHouse password |
SECRET_KEY |
JWT signing secret |
CORS_ORIGINS |
Allowed frontend origins |
CORS_ORIGIN_REGEX |
Optional regex for local/dev frontend origins |
READS_PATH |
BAM/CRAM directory |
REFERENCE_FASTA_PATH |
Reference FASTA for sequence/CRAM lookups |
REFERENCE_ALIAS_PATH |
Optional chromosome alias map |
REFERENCE_CYTOBAND_PATH |
Optional cytoband fallback file |
GENE_REFERENCE_DBNSFP_GENE_PATH |
Local dbNSFP gene file for gene reference sync; defaults to /data/ref-data/dbNSFP5.3_gene.gz and online sources are used as fallback |
GENE_REFERENCE_BOOTSTRAP_ON_STARTUP |
Queue the first dbNSFP-backed human gene reference sync on startup when GRCh38 genes exist and gene_info is still empty; defaults to true |
VITE_API_BASE_URL |
Frontend API base URL; defaults to same-origin /api, proxied to the backend |
Check containers:
docker compose ps
docker compose logs backend --tail=100
docker compose logs postgres --tail=100
docker compose logs clickhouse --tail=100Check backend env inside the container:
docker exec coga-backend-1 printenv | egrep '^(POSTGRES_|CLICKHOUSE_|SECRET_KEY|READS_PATH|REFERENCE_)'- Metadata issues usually come from Postgres schema or bad UUID references.
- Variant ingestion/listing issues usually come from ClickHouse schema or assembly table creation.
- The Administration data-management page now includes a ClickHouse variant operations section for inspecting per-assembly table status and running ensure/optimize actions.
- The same maintenance API is available through:
GET /admin/clickhouse/variantsPOST /admin/clickhouse/variants/{assembly_name}/ensurePOST /admin/clickhouse/variants/{assembly_name}/optimize