Sign inSign up

scani/api

By scani

•Updated 2 days ago

Scani tRPC + Elysia API server. Self-hostable portfolio tracker. github.com/MGrin/scani-oss

Image
0

9.6K

scani/api repository overview

⁠scani/api

tRPC + Elysia HTTP server for Scani⁠ — the self-hostable, open-source portfolio tracker for crypto and traditional assets.

Owns per-user credentialed integrations (exchange API keys, brokerage tokens) so user credentials never cross the tenant boundary. Enqueues async work onto Postgres (BullMQ's Postgres backend) for scani/worker⁠ to consume.

⁠Tags

  • latest — highest semver release tag
  • 1.2.3 / 1.2 / 1 — semver release tags

Pin SCANI_IMAGE_TAG=1.2.3 in your .env for reproducible deploys.

⁠Quick start

The recommended way to run this image is via the reference docker-compose.prod.yml⁠ in the OSS repo — it wires this image up with Postgres, Redis, SeaweedFS, scani/worker⁠, scani/data-provider⁠, and scani/frontend-app⁠:

git clone https://github.com/MGrin/scani-oss.git
cd scani-oss
SCANI_SKIP_UP=1 ./scripts/self-host.sh

# Apply schema migrations (do this on first install AND on every upgrade)
docker compose -f docker-compose.prod.yml --profile migrate run --rm migrate

# Bring the long-running services up
docker compose -f docker-compose.prod.yml up -d

Migrations live in a separate scani/migrate⁠ image and run as an opt-in --profile migrate step — see the self-hosting docs⁠ for the why, the alternative orchestrators (Kubernetes Job, CI deploy step, standalone docker run), and what happens if you skip them (api's /readyz returns 503).

⁠Required environment variables

VariablePurpose
DATABASE_URLPostgres 16+ connection string
REDIS_URLRedis 7+ connection string
BETTER_AUTH_SECRET32+ chars; signs sessions
ENCRYPTION_KEY32 hex chars; must match scani/worker
JOBS_HMAC_SECRETSigns the worker wake ping and the admin audit log
FRONTEND_URL / BACKEND_URLWhat the browser sees; powers CORS + cookies
S3_*Object storage (any S3-compatible store)
SCANI_CLOUD_URL / SCANI_CLOUD_API_KEYWhere scani/data-provider lives + bearer to reach it

Full annotated list: .env.example⁠.

⁠Source

Full source, architecture, and contribution guidelines: https://github.com/MGrin/scani-oss⁠

MIT licensed.

Tag summary

Content type

Image

Digest

sha256:45078ddf3…

Size

87.6 MB

Last updated

2 days ago

docker pull scani/api