/ builds

Things I run in production

Side projects I designed, deployed and operate myself. Hover a service to trace its connections.

/builds/beacon-trader

Beacon Trader

An automated trading portal, built from scratch.

  • Six containerised microservices on Docker Compose: API (FastAPI), Telegram signal ingestion (Telethon), executor, monitor, Redis, and a React/Vite frontend, with PostgreSQL for persistence
  • Signal parsing, risk sizing with live FX conversion, and order fan-out (entries × take-profits)
  • A broker abstraction, so execution logic never talks to a vendor SDK directly
⚠ postmortem · Broker API session quota exhausted
cause
Two applications shared one broker API key, so together they exhausted that key's session quota.
fix
A dedicated API key per application, so one app's sessions can never starve another's.
FastAPITelethonRedisPostgreSQLReactDocker Compose
signals publish consume rates orders positions https Telegram channels Signal ingestion Redis Live FX rates Executor Broker APIs Monitor PostgreSQL API · FastAPI Frontend · React Operator
Trace a serviceHover, tap or tab to a node to see what it does and what it talks to.
Telegram channels
Signal providers post trade ideas in Telegram channels. This is the platform's only inbound event source.
Signal ingestion
A Telethon client that listens to the channels, parses free-text signals into structured intents, and publishes them to Redis.
Redis
The event bus and working cache between ingestion, the API and the executor.
Live FX rates
Live conversion rates, so risk is sized in account currency, whatever the instrument is quoted in.
Executor
Sizes risk, then fans each signal out into orders (entries × take-profits) through the broker abstraction.
Broker APIs
Reached only through the broker abstraction. Each application has its own API key (see the postmortem below).
Monitor
Watches open positions and broker state, reconciles them with the ledger, and raises alerts.
PostgreSQL
The system of record: signals, orders, fills, positions and configuration.
API · FastAPI
A REST API for the console: configuration, channel strategies, positions and history.
Frontend · React
The operator console, built with React and Vite and served as a static build.
Operator
Me. On call for everything on this diagram.
/builds/beacon-screener

Beacon Screener

A MENA + US stock screening platform.

  • A trading-bot module: Telegram signals, per-channel strategy parameters, manual execution with fan-out, and a broker abstraction with position management
  • A scraper microservice (Playwright) that feeds PostgreSQL
  • Runs on the same self-operated infrastructure as Beacon Trader
PlaywrightPostgreSQLPythonDocker Compose
scrape write https signals orders Market sources Scraper · Playwright PostgreSQL Screener API Screener web app Users Telegram signals Trading bot module Broker abstraction
Trace a serviceHover, tap or tab to a node to see what it does and what it talks to.
Market sources
Public market data for MENA and US listings.
Scraper · Playwright
A headless-browser microservice. It collects, normalises and writes to PostgreSQL on a schedule.
PostgreSQL
Listings, prices, fundamentals and screen results.
Screener API
Screens, filters and rankings served to the web app.
Screener web app
The browser UI for building screens and reviewing candidates.
Users
Signed-in users.
Telegram signals
Signal channels, each with its own strategy parameters.
Trading bot module
Per-channel strategy parameters, manual execution with order fan-out, and position management.
Broker abstraction
One interface over the broker APIs, including position management.
/infrastructure

The infrastructure behind both

Self-operated cloud: one engineer, no platform team.

  • OCI me-dubai-1, ARM compute, Oracle Linux 9
  • Docker Compose per application; managed PostgreSQL
  • A load balancer terminating TLS, with DNS-validated certificates
OCIOracle Linux 9Docker ComposePostgreSQLTLS
resolve https import http pull & rebuild Visitors DNS Load balancer · TLS DNS-validated certs Compute · OL9 Docker Compose PostgreSQL GitHub
Trace a serviceHover, tap or tab to a node to see what it does and what it talks to.
Visitors
Browsers and API clients on the public internet.
DNS
Public zone records. They also serve the DNS-01 challenges for certificate validation.
Load balancer · TLS
Terminates TLS, redirects HTTP to HTTPS and health-checks the backends.
DNS-validated certs
Wildcard certificates issued by DNS-01 validation and imported to the load balancer. The listener is re-pointed after every import.
Compute · OL9
Oracle Linux 9 VMs in me-dubai-1, hardened with firewalld and reachable only through the load balancer.
Docker Compose
Each application is a Compose stack: reverse proxy, app services, workers.
PostgreSQL
Managed or containerised PostgreSQL with daily dumps.
GitHub
The source of truth. Deploying is git pull plus docker compose up -d --build.