A comprehensive wind analysis platform for cycling routes. Upload your GPX files and get detailed wind condition analysis to plan your rides better.
This is a mono-repo containing:
api/- FastAPI backend with wind analysis engineui/- Next.js frontend with interactive map visualizationapi.dockerfile- Docker configuration for API serviceui.dockerfile- Docker configuration for UI service
Key technologies include Python, FastAPI, Next.js, React, PostgreSQL, Redis, and Docker.
This project can be run entirely with Docker or in a hybrid mode with the UI/API running locally.
-
Clone the repository:
git clone https://github.com/AnsonDev42/against-wind cd against-wind -
Run the setup script (recommended):
chmod +x scripts/dev-setup.sh ./scripts/dev-setup.sh
This will:
- Check prerequisites
- Create
.envfrom template - Install API dependencies with
uv - Install UI dependencies with
npm
-
Manual setup (alternative):
cp .env.example .env uv sync cd ui && pnpm install && cd ..
This is the simplest way to get all services running.
-
Build and Start Services:
docker-compose up --build -d
-
Access the Application:
- UI: http://localhost:3000
- API: http://localhost:8000/docs
- MinIO Console: http://localhost:9001
Run the UI and API on your local machine for faster development, while keeping stateful services (Postgres, Redis, MinIO) in Docker.
-
Start Background Services:
docker-compose up -d postgres redis minio
-
Run the Backend (API): In a new terminal, install dependencies and run the server from the root directory.
uv sync uv run alembic upgrade head # Apply database migrations uv run uvicorn api.app.main:app --reload -
Run the Frontend (UI): In another terminal, navigate to the
uidirectory and usepnpmto install dependencies and start the development server.cd ui pnpm install pnpm dev
When you change a database model in the API, you'll need to generate a new migration.
# From the root directory
cd api && uv run alembic revision --autogenerate -m "Your description of the change"
cd api && uv run alembic upgrade head# Backend tests (from root directory)
uv run pytest api/tests/
# Frontend tests (from ui/ directory)
cd ui && pnpm testTBD