version: '3.8' services: postgres: image: timescale/timescaledb:latest-pg16 container_name: findable-postgres environment: POSTGRES_DB: findable POSTGRES_USER: findable POSTGRES_PASSWORD: findable_dev_password ports: - '5432:5432' volumes: - postgres_data:/var/lib/postgresql/data - ./docker/postgres/init.sql:/docker-entrypoint-initdb.d/init.sql healthcheck: test: ['CMD-SHELL', 'pg_isready -U findable'] interval: 10s timeout: 5s retries: 5 redis: image: redis:7-alpine container_name: findable-redis command: redis-server --appendonly yes ports: - '6379:6379' volumes: - redis_data:/data healthcheck: test: ['CMD', 'redis-cli', 'ping'] interval: 10s timeout: 5s retries: 5 api: build: context: . dockerfile: ./docker/api/Dockerfile container_name: findable-api ports: - '3001:3001' environment: NODE_ENV: development DATABASE_URL: postgresql://findable:findable_dev_password@postgres:5432/findable REDIS_HOST: redis REDIS_PORT: 6379 JWT_SECRET: dev_jwt_secret_change_in_production PORT: 3001 HOST: 0.0.0.0 depends_on: postgres: condition: service_healthy redis: condition: service_healthy volumes: - ./apps/api:/app/apps/api - ./packages:/app/packages - /app/node_modules - /app/apps/api/node_modules command: npm run dev --workspace=@findable/api web: build: context: . dockerfile: ./docker/web/Dockerfile container_name: findable-web ports: - '3000:3000' environment: NEXT_PUBLIC_API_URL: http://localhost:3001 depends_on: - api volumes: - ./apps/web:/app/apps/web - ./packages:/app/packages - /app/node_modules - /app/apps/web/node_modules - /app/apps/web/.next command: npm run dev --workspace=@findable/web volumes: postgres_data: redis_data: