It is a minimal, registration-free web application that allows multiple users to share their real-time geolocation on an interactive map. Users create or join a room by sharing a link, grant location access, and instantly see all other participants' locations on a shared map.
Try the live demo: https://nothere.rilshok.workers.dev/
This repository demonstrates the capability of building a full-featured backend in pure Python with FastAPI and deploying it to Cloudflare's serverless infrastructure. The build and deployment process leverages Pyodide (a port of CPython to WebAssembly) enabling Python code execution directly within V8 isolates on Cloudflare's edge servers. This project serves as a proof of concept, showcasing how modern serverless platforms unlock new possibilities for Python-based backend development.
Stack:
- Backend: Python FastAPI running on Cloudflare Workers
- Frontend: React + Vite + Leaflet (maps)
- Storage: Cloudflare Durable Objects for persistent state
.
├── frontend/ # React application
│ ├── dist/ # Production build
│ ├── src/ # Source code
│ │ ├── components/ # React components
│ │ ├── hooks/ # Custom hooks
│ │ ├── pages/ # Application pages
│ │ ├── main.tsx # Entry point
│ │ └── App.tsx # Root component
│ ├── vite.config.ts # Vite configuration
│ └── tsconfig.json # TypeScript configuration
├── src/ # Python backend
│ ├── entry.py # Worker entrypoint
│ ├── durable.py # Durable Objects classes
│ ├── dependency.py # Dependencies and configuration
│ └── routes/ # API routes
├── pyproject.toml # Python dependencies
├── package.json # Node.js dependencies
├── wrangler.jsonc # Cloudflare Workers configuration
└── .dev.vars # Environment variables (development)
curl -fsSL https://deb.nodesource.com/setup_lts.x | sudo -E bash -
sudo apt install -y nodejsFast Python package manager (installation guide)
curl -LsSf https://astral.sh/uv/install.sh | shCreate a .dev.vars file in the project root:
JWT_TOKEN=your_jwt_secret_key_herenpm install
uv run pywrangler devuv run pywrangler deploy