version: '3.8' services: calendar-widget-api: build: . image: git.tunpok.com/ching/calendar-widget-api:latest container_name: calendar-widget-api restart: unless-stopped environment: - PORT=5000 - API_KEY=${API_KEY:-change-me} - TASK_DB=/app/data/tasks.db - GOOGLE_CREDENTIALS_FILE=/app/credentials.json - CALENDAR_ID=${CALENDAR_ID:-primary} ports: - "5000:5000" volumes: # 数据持久化 - ./data:/app/data # Google Calendar 凭证文件(可选,如果存在) - ./credentials.json:/app/credentials.json:ro