version: '2'
services:
  php:
    image: yiisoftware/yii2-php:5.6-apache
    volumes:
      - ~/.composer-docker/cache:/root/.composer/cache:delegated
      - ./:/app:delegated
    ports:
      - '8004:80'
  local:
    image: mariadb:10.7
    environment:
      - MYSQL_ROOT_PASSWORD=root
      - MYSQL_DATABASE=mylocal
    ports:
      - '3307:3306'
    expose:
      - '3307'
    command: ['mysqld', '--character-set-server=utf8', '--collation-server=utf8_unicode_ci']