version: '3.8'
services:
  app:
    build:
      context: .
      dockerfile: Dockerfile
    image: carfi-crm-back
    container_name: carfi-crm-back-app
    restart: unless-stopped
    ports:
      - "8000:80"
    volumes:
      - ./:/var/www/html
      - /var/www/html/vendor
    environment:
      APP_ENV: local
      APP_DEBUG: 'true'
      APP_KEY: ${APP_KEY}
      DB_CONNECTION: mysql
      DB_HOST: host.docker.internal
      DB_PORT: 3306
      DB_DATABASE: crm_carfi
      DB_USERNAME: desarrollo
      DB_PASSWORD: ${DB_PASSWORD}
    extra_hosts:
      - "host.docker.internal:host-gateway"
    networks:
      - carfi-network

networks:
  carfi-network:
    driver: bridge
