services:
  gitara-web:
    container_name: gitara-web
    build:
      context: .
      dockerfile: Dockerfile
    extra_hosts:
      - "host.docker.internal:host-gateway"
    env_file:
      - .env.production
    volumes:
      - gitara_web_data:/usr/app/data
    networks:
      - gitara-net
    restart: unless-stopped
    healthcheck:
      test: ["CMD-SHELL", "curl -fsS http://localhost:5150/_ping"]
      interval: 30s
      timeout: 5s
      retries: 3
      start_period: 20s

networks:
  gitara-net:
    external: true

volumes:
  gitara_web_data:
    external: true
    name: gitara_web_data
