version: '3.1'

services:
  wordpress:
    image: wordpress:6.4-php8.0-apache
    ports:
      - "8000:80"
    environment:
      WORDPRESS_DB_HOST: db
      WORDPRESS_DB_USER: pashatboss
      WORDPRESS_DB_PASSWORD: naffco!Q@W#E
      WORDPRESS_DB_NAME: tboss_wp
    volumes:
      - wordpress_data:/var/www/html
      - ./php.ini:/usr/local/etc/php/conf.d/uploads.ini
    restart: unless-stopped

  db:
    image: mysql:5.7
    volumes:
      - db_data:/var/lib/mysql
      - ./my_custom.cnf:/etc/mysql/conf.d/my_custom.cnf
    ports:
      - "3307:3306"
    environment:
      MYSQL_ROOT_PASSWORD: naffco!Q@W#E
      MYSQL_DATABASE: tboss_wp
      MYSQL_USER: pashatboss
      MYSQL_PASSWORD: naffco!Q@W#E
    restart: unless-stopped

volumes:
  wordpress_data:
  db_data:

