initial project setup with README and ignore
This commit is contained in:
36
docker-compose.yml
Normal file
36
docker-compose.yml
Normal file
@@ -0,0 +1,36 @@
|
||||
version: "3.9"
|
||||
|
||||
networks:
|
||||
frontend:
|
||||
external: true
|
||||
|
||||
services:
|
||||
routes_api:
|
||||
build:
|
||||
context: .
|
||||
dockerfile: Dockerfile
|
||||
image: routes-api:latest
|
||||
container_name: routes_api
|
||||
restart: unless-stopped
|
||||
environment:
|
||||
- UVICORN_WORKERS=2
|
||||
- REDIS_URL=redis://:${REDIS_PASSWORD}@routes_redis:6379/0
|
||||
# Optional: Set cache TTL in seconds (default: 300 = 5 min, 86400 = 24h)
|
||||
# Uncomment and set in .env file: REDIS_CACHE_TTL_SECONDS=86400
|
||||
# - REDIS_CACHE_TTL_SECONDS=${REDIS_CACHE_TTL_SECONDS}
|
||||
# Google Maps API key for accurate road distance calculation (actualkms)
|
||||
# Set in .env file: GOOGLE_MAPS_API_KEY=your_api_key_here
|
||||
- GOOGLE_MAPS_API_KEY=${GOOGLE_MAPS_API_KEY}
|
||||
labels:
|
||||
- traefik.enable=true
|
||||
- traefik.http.routers.routes_api.rule=Host(`routes.workolik.com`)
|
||||
- traefik.http.routers.routes_api.entrypoints=websecure
|
||||
- traefik.http.routers.routes_api.tls.certresolver=letsencrypt
|
||||
- traefik.http.services.routes_api.loadbalancer.server.port=8002
|
||||
- traefik.docker.network=frontend
|
||||
volumes:
|
||||
- ./ml_data:/app/ml_data
|
||||
- ./rider_history.pkl:/app/rider_history.pkl
|
||||
- ./rider_active_state.pkl:/app/rider_active_state.pkl
|
||||
networks:
|
||||
- frontend
|
||||
Reference in New Issue
Block a user