Files
github-readme-stats/edge
shayandClaude Opus 5.5 74a8146779 feat(deploy): log one access line per request to stdout
Each gunicorn service (edge, fetcher, generator) now writes a request line
("GET /x HTTP/1.1" 200 12ms) to stdout, which Pantheos ingests for request
logs and rps / 5xx / p95. /metrics and /health are left out.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-09 10:50:32 -04:00
..
2026-04-17 17:09:00 -04:00

Edge Service

Cache-first SVG proxy in front of the generator. Deploy many instances around the world. No DB of its own; optional Redis for shared cache.

Run locally

cd edge
pip install -r requirements.txt
GENERATOR_URL=http://localhost:5002 python -m src.api

Test

cd edge && pytest

Docker

docker build -t ghstats-edge .
docker run --rm -e GENERATOR_URL=http://host.docker.internal:5002 -p 5003:5003 ghstats-edge

Endpoints

Method Path Description
GET /health cache type + upstream reachability
GET / composite SVG (cached on X-Widget-Status: ready)
GET //.svg individual widget SVG

Env

  • GENERATOR_URL — origin (required)
  • CACHE_TYPE — SimpleCache (default) or RedisCache
  • CACHE_REDIS_URL — if using RedisCache
  • CACHE_DEFAULT_TIMEOUT — seconds, default 86400
  • CACHE_THRESHOLD — max entries (SimpleCache only), default 10000