Australian Securities Exchange stock data platform. Four repos, two servers.
asx/ ← this repo (docs, crontab)
├── asx-data/ ← stock data pipeline + REST API (port 8082)
├── asx-web/ ← Flask web frontend (port 7000)
└── asx-announcements/ ← ASX announcements scraper + FastAPI server (port 8081)
| Machine | Role |
|---|---|
| server | Primary server; runs all three services |
| realiti-wsl (local WSL2) | GPU analysis only (RTX 4070); runs asx-data/analysis/sync.sh |
| Service | Port | Repo | Systemd unit |
|---|---|---|---|
| Stock data API | 8082 | asx-data | asx-backend.service |
| Announcements API | 8081 | asx-announcements | asx-announcements.service |
| Web frontend | 7000 | asx-web | asx-web.service |
# Backend API
sudo systemctl restart asx-backend
# Announcements
sudo systemctl restart asx-announcements
# Web frontend
sudo systemctl restart asx-webThe unified crontab lives at asx/crontab. Install on your server:
crontab $HOME/code/asx/crontabasx-data/stockdb/stockdb.db ←─ fetch_shorts, fetch_eod_daily, fetch_symbols (server cron)
←─ fetch_symbol_changes, fetch_options (server cron)
←─ fetch_commodities, fetch_trading_economics (server cron)
←─ fetch_metals_dev, fetch_manganese (server cron)
←─ analysis/sync.sh (realiti-wsl)
↓
asx-data/backend/api.py (port 8082)
↓
asx-web/asx.py (port 7000, proxies to backend)
stockdb/stockdb.db (primary, ~1GB):
symbols— listed companies (name, industry, shares outstanding)endofday— daily OHLCV pricesendofmonth— monthly closesshorts— daily short positions (ASIC data, 2010–present)corporate_events— splits etc.symbol_changes— ASX code renames (old → new)asx_options— ASX-listed warrants (IB Gateway primary, Markit fallback)commodity_meta— 25 tracked commodities with units and source infocommodity_prices— daily/weekly commodity prices (4 sources: yfinance, Trading Economics, metals.dev, Jupiter Mines)
users.db (asx-web only, gitignored):
users,list_groups,lists,watchlist_items,portfolio_itemstransactions,algorithms,recommendations,list_column_prefsresearch_reports,research_folders— broker research with AI-extracted price targetsalerts,alert_conditions— price and event alerts per userfermi_reports,fermi_api_calls— AI-generated Fermi analysis reportsdashboard_preferences— per-user dashboard widget configuser_feature_changes— audit log for admin feature toggling