version: "3"

services:
  laravel:
    build:
      context: .
    working_dir: /var/www
    volumes:
      - ./:/var/www
      - ./docker/docker.env:/var/www/.env
    entrypoint: bash laravue-entrypoint.sh
    ports:
      - "8000:8000"

    depends_on:
      - mysql
      - redis

  redis:
    image: redis:alpine

  mysql:
    image: mysql:5.7
    ports:
      - "3306:3306"
    volumes:
      - ./docker/mysql:/var/lib/mysql
    environment:
      MYSQL_DATABASE: laravue
      MYSQL_USER: laravue
      MYSQL_PASSWORD: laravue
      MYSQL_ROOT_PASSWORD: root

