
version: '3.8'
services:
  app:
    image: php:8.1-fpm
    working_dir: /var/www/html
    volumes:
      - ./:/var/www/html
    depends_on:
      - db
      - redis
  db:
    image: mysql:8.0
    environment:
      MYSQL_ROOT_PASSWORD: secret
      MYSQL_DATABASE: ai_builder
      MYSQL_USER: ai
      MYSQL_PASSWORD: secret
    ports:
      - '3306:3306'
  redis:
    image: redis:6
    ports:
      - '6379:6379'
  nginx:
    image: nginx:latest
    ports:
      - '8080:80'
    volumes:
      - ./:/var/www/html
      - ./nginx/conf.d:/etc/nginx/conf.d
