Skip to main content

Component Map

Runtime topology

Internet (optional — not required for core operation)
|
MikroTik Router (LAN gateway + captive portal)
|
+--- Wi-Fi / Ethernet LAN
|
+---------+----------+
| |
Android devices Server host (Linux, systemd)
(mobile-app) |
| +-- [nginx :443] (TLS reverse proxy)
| | |
| | +-- [gunicorn :8000] (SAPOT FastAPI)
| | | |
| | | +-- [MariaDB :3306]
| | | |
| | | +-- [Redis :6379] (WS pub-sub)
| | |
| | +-- [tileserver-gl :8080, 127.0.0.1 only]
| |
| +-- [GSM-API] (FastAPI + pyserial -> Arduino/modem)
|
+--- Direct P2P (WebRTC media/data, LAN TCP+TLS)
to other Android devices on the same LAN

For the security trust boundaries overlaid on this same topology (which zones are trusted vs. semi-trusted), see threat-model.md.


Services and ports

ServiceProcessListensProxied by
SAPOT FastAPI servergunicorn + uvicorn workers127.0.0.1:8000Nginx :443
Nginx reverse proxynginx0.0.0.0:443 (TLS), :80 (redirect)
MariaDBmysqld127.0.0.1:3306— (server-internal)
Redisredis-server127.0.0.1:6379— (server-internal)
GSM module APIuvicorn (GSM-fastapi/main.py)127.0.0.1:8001 (hardcoded, PORT var has no effect)— (see environment-config.md)
Tileservertileserver-gl127.0.0.1:8080Nginx :443 at /tiles/ (see tileserver.md)
Admin frontendnext start127.0.0.1:3000Nginx (see admin-frontend.md)

Nginx routing

PathUpstreamNotes
/ws/http://127.0.0.1:8000WebSocket — no proxy read timeout (86400 s)
/static/FilesystemServed directly by Nginx; 30-day cache
/tiles/http://127.0.0.1:8080Tileserver styles; prefix stripped by trailing / on proxy_pass
/data/, /fonts/, /sprites/http://127.0.0.1:8080TileServer GL assets referenced by its absolute style URLs
/ (all other)http://127.0.0.1:8000Standard proxy; 155 s read timeout

HTTP (port 80) redirects to HTTPS with 301.


systemd services (known)

UnitComponent
server-main-api.serviceSAPOT FastAPI server
server-GSM-api.serviceGSM module API
tileserver.serviceOffline tile server

Note: Verify exact unit names from deployment-scripts/ or the server directory.


Mobile app connectivity

ProtocolTargetPurpose
HTTPSServer (via Nginx)REST API calls
WSSServer /ws/Signalling, presence, message relay
WSSServer /gps/ws/GPS streaming
WebRTC (P2P)Other devicesVoice/video calls, data channel
LAN TCP + TLSOther devicesDirect peer messaging
mDNS / ZeroconfLAN broadcastPeer discovery

See data-flow.md for detailed message and call flows.