This guide walks you through running GeoViable on your local machine using Docker Compose. By the end you will have all three services running — the PostGIS database, the FastAPI backend, and the Nginx-served React frontend — and the environmental layer data loaded so that analysis requests return real results.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/danizd/geoviable/llms.txt
Use this file to discover all available pages before exploring further.
Prerequisites
Make sure the following tools are installed and available on your
Windows users: A
PATH before starting:| Tool | Minimum version | Purpose |
|---|---|---|
| Docker | 24.0+ | Container runtime |
| Docker Compose | 2.20+ | Multi-container orchestration |
| Node.js | 18.x (LTS) | Frontend build (npm run build) |
| Python | 3.11+ | Local backend development (optional) |
| Git | — | Cloning the repository |
start.bat convenience script is included at the repository root. It wraps the key Docker Compose commands for Command Prompt / PowerShell users who prefer not to type the full commands manually.Configure environment variables
Copy the provided template and open it in your editor:The key variables you must review and set are:
| Variable | Description | Default |
|---|---|---|
POSTGRES_DB | PostgreSQL database name | geoviable |
POSTGRES_USER | PostgreSQL username | geoviable |
POSTGRES_PASSWORD | PostgreSQL password — change this | CHANGE_ME_SECURE_PASSWORD |
DATABASE_URL | SQLAlchemy connection string | postgresql+psycopg2://geoviable:CHANGE_ME_SECURE_PASSWORD@geoviable-db:5432/geoviable |
ENVIRONMENT | Runtime mode | production |
LOG_LEVEL | Python logging verbosity | INFO |
CORS_ORIGINS | Comma-separated allowed origins | https://geoviable.movilab.es |
For a production deployment, generate a cryptographically strong password with:Set the generated value in both
POSTGRES_PASSWORD and the password field inside DATABASE_URL. Also update CORS_ORIGINS to your actual domain, e.g. CORS_ORIGINS=https://geoviable.movilab.es.Build the frontend
The Nginx container serves React as pre-compiled static files from This produces the production-optimised bundle in
frontend/build/. You must build the frontend before starting Docker services for the first time, and again after any changes to frontend/src/.frontend/build/, which is then bind-mounted read-only into the Nginx container.Start services
Build the Docker images and bring all three containers up in detached mode:Check that all containers are running and healthy:You should see
geoviable-db, geoviable-api, and geoviable-web all in a running state. The API container waits for the database health check to pass before starting, so allow 20–30 seconds on first boot.Verify installation
Once all containers are healthy, the following URLs should be reachable from your browser or
If the health check returns
curl:| Service | URL | What you should see |
|---|---|---|
| Frontend | http://localhost:3000 | GeoViable React map interface |
| API Docs | http://localhost:8000/api/v1/docs | FastAPI Swagger UI |
| Health check | http://localhost:8000/api/v1/health | {"status":"healthy","database":"connected","version":"1.0.0"} |
"database":"disconnected", check the database container logs with docker compose logs geoviable-db.Load environmental data
The PostGIS database is structurally ready (tables and indexes created automatically by
Then run the loader script inside the API container:The script prints a row count for each table when it finishes. Every count should be greater than zero. If a specific layer fails, you can reload it individually using the Valid values for
backend/initdb/01_init.sql on first run), but it contains no spatial data yet. Environmental layer data must be loaded manually.Request the ZIP files from daniel.zas.dacosta@gmail.com. These are pre-processed shapefiles sourced from MITECO and CNIG, clipped to Galicia and normalised to EPSG:25830.Once you have the ZIPs, place them in backend/data/ using these exact filenames:| File | Layer |
|---|---|
red_natura_2000.zip | Red Natura 2000 (ZEPA + LIC/ZEC) |
zonas_inundables_t100.zip | Flood zones — T100 return period |
zonas_inundables_t500.zip | Flood zones — T500 return period |
dph.zip | Hydraulic Public Domain (DPH) |
vias_pecuarias.zip | Livestock paths |
enp.zip | Protected Natural Spaces (ENP) |
masas_agua_superficial.zip | Surface water bodies |
masas_agua_subterranea.zip | Groundwater bodies |
--layer flag:--layer are: red_natura_2000, zonas_inundables, dominio_publico_hidraulico, vias_pecuarias, espacios_naturales_protegidos, masas_agua_superficial, masas_agua_subterranea.Once the data is loaded, open http://localhost:3000, draw a polygon over Galicia, and click Load layers — you should see coloured overlays appear on the map.