mirror of
https://github.com/Memo-2023/mana-monorepo.git
synced 2026-05-20 07:33:39 +02:00
New mana-geocoding service (port 3018) wraps a self-hosted Pelias instance with LRU caching and OSM→PlaceCategory auto-mapping. All geocoding queries stay within our infrastructure — no user location data leaves the network. Places module integration: - Address autocomplete search in ListView (creates place with name, coords, address, category in one step) - Address search + reverse geocoding button in DetailView - Auto-fill address via reverse geocoding during tracking - OSM category mapping (amenity:restaurant→food, shop:*→shopping, etc.) Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
107 lines
2.4 KiB
YAML
107 lines
2.4 KiB
YAML
# Pelias geocoding stack for mana-geocoding.
|
|
#
|
|
# Data pipeline: download → prepare → import → serve.
|
|
# See pelias/README.md for initial setup instructions.
|
|
#
|
|
# After import, only `api` and `libpostal` need to stay running.
|
|
# The import containers (placeholder, interpolation, pip, elasticsearch)
|
|
# run during import and can be stopped afterward if RAM is tight,
|
|
# but elasticsearch must stay up for queries.
|
|
|
|
services:
|
|
# --- Always running ---
|
|
|
|
api:
|
|
image: pelias/api:latest
|
|
container_name: pelias-api
|
|
restart: unless-stopped
|
|
ports:
|
|
- "4000:4000"
|
|
environment:
|
|
PORT: 4000
|
|
volumes:
|
|
- ./pelias.json:/code/pelias.json:ro
|
|
depends_on:
|
|
elasticsearch:
|
|
condition: service_healthy
|
|
networks:
|
|
- pelias
|
|
|
|
libpostal:
|
|
image: pelias/libpostal-service
|
|
container_name: pelias-libpostal
|
|
restart: unless-stopped
|
|
ports:
|
|
- "4400:4400"
|
|
networks:
|
|
- pelias
|
|
|
|
elasticsearch:
|
|
image: pelias/elasticsearch:7.17.1
|
|
container_name: pelias-elasticsearch
|
|
restart: unless-stopped
|
|
ports:
|
|
- "9200:9200"
|
|
volumes:
|
|
- pelias-elasticsearch:/usr/share/elasticsearch/data
|
|
environment:
|
|
ES_JAVA_OPTS: "-Xms512m -Xmx512m"
|
|
ulimits:
|
|
memlock:
|
|
soft: -1
|
|
hard: -1
|
|
healthcheck:
|
|
test: ["CMD", "curl", "-f", "http://localhost:9200/_cluster/health"]
|
|
interval: 10s
|
|
timeout: 5s
|
|
retries: 30
|
|
networks:
|
|
- pelias
|
|
|
|
# --- Import pipeline (run once, then stop) ---
|
|
|
|
schema:
|
|
image: pelias/schema:latest
|
|
container_name: pelias-schema
|
|
volumes:
|
|
- ./pelias.json:/code/pelias.json:ro
|
|
depends_on:
|
|
elasticsearch:
|
|
condition: service_healthy
|
|
networks:
|
|
- pelias
|
|
profiles: ["import"]
|
|
|
|
openstreetmap:
|
|
image: pelias/openstreetmap:latest
|
|
container_name: pelias-openstreetmap
|
|
volumes:
|
|
- ./pelias.json:/code/pelias.json:ro
|
|
- pelias-data:/data
|
|
depends_on:
|
|
elasticsearch:
|
|
condition: service_healthy
|
|
networks:
|
|
- pelias
|
|
profiles: ["import"]
|
|
|
|
polylines:
|
|
image: pelias/polylines:latest
|
|
container_name: pelias-polylines
|
|
volumes:
|
|
- ./pelias.json:/code/pelias.json:ro
|
|
- pelias-data:/data
|
|
depends_on:
|
|
elasticsearch:
|
|
condition: service_healthy
|
|
networks:
|
|
- pelias
|
|
profiles: ["import"]
|
|
|
|
volumes:
|
|
pelias-elasticsearch:
|
|
pelias-data:
|
|
|
|
networks:
|
|
pelias:
|
|
driver: bridge
|