services:
  baihu-dev:
    build:
      context: .
      dockerfile: docker/Dockerfile.dev
    container_name: baihu-dev
    ports:
      - "8052:8052"
      - "5173:5173"
    volumes:
      - .:/app:Z
      - baihu-envs:/app/envs
      - baihu-node-modules:/app/web/node_modules
      - go-path:/go
      - npm-cache:/var/cache/npm
    environment:
      - TZ=Asia/Shanghai
      - DEV_UID=${DEV_UID:-1000}
      - DEV_GID=${DEV_GID:-1000}
      - MISE_YES=1  # Auto-confirm mise prompts
    stdin_open: true
    tty: true

volumes:
  baihu-envs:
    name: baihu_dev_envs
  baihu-node-modules:
    name: baihu_dev_node_modules
  go-path:
    name: baihu_dev_go_path
  npm-cache:
    name: baihu_dev_npm_cache
