version: '3'
services:
  pageperpage:
    build: .
    volumes:
      - ~/.composer-docker/cache:/root/.composer/cache:delegated
      - ./:/var/www/html:delegated
      - ../pageperpage.com_shared/var/ppp:/var/ppp:delegated
      - ../pageperpage.com_shared/var/ppp/aging_history:/var/ppp/aging_history:delegated
      - ../pageperpage.com_shared/var/ppp/automation_cached:/var/ppp/automation_cached:delegated
      - ../pageperpage.com_shared/mnt/HOA-orderdata1/ballotdata/:/var/ppp/ballotdata:delegated
      - ../pageperpage.com_shared/mnt/HOA-orderdata1/batch_invoices/:/var/ppp/batch_invoices:delegated
      - ../pageperpage.com_shared/mnt/HOA-orderdata1/batch_print_files/:/var/ppp/batch_print_files:delegated
      - ../pageperpage.com_shared/var/ppp/candidateimage:/var/ppp/candidateimage:delegated
      - ../pageperpage.com_shared/var/ppp/ci_sess_files:/var/ppp/ci_sess_files:delegated
      - ../pageperpage.com_shared/var/ppp/clientdata:/var/ppp/clientdata:delegated
      - ../pageperpage.com_shared/var/ppp/client_files:/var/ppp/client_files:delegated
      - ../pageperpage.com_shared/var/ppp/estatements:/var/ppp/estatements:delegated
      - ../pageperpage.com_shared/mnt/HOA-orderdata1/hoa_gallery/:/var/ppp/hoa_gallery:delegated
      - ../pageperpage.com_shared/var/ppp/hoampage_api_orders:/var/ppp/hoampage_api_orders:delegated
      - ../pageperpage.com_shared/mnt/HOA-orderdata1/hoampage_documents/:/var/ppp/hoampage_documents:delegated
      - ../pageperpage.com_shared/mnt/HOA-orderdata1/hoampage_users/:/var/ppp/hoampage_users:delegated
      - ../pageperpage.com_shared/var/ppp/localorders:/var/ppp/localorders:delegated
      - ../pageperpage.com_shared/mnt/HOA-orderdata1:/var/ppp/orderdata:delegated
      - ../pageperpage.com_shared/var/ppp/pdf_api_batches:/var/ppp/pdf_api_batches:delegated
      - ../pageperpage.com_shared/var/ppp/reports:/var/ppp/reports:delegated
      - ../pageperpage.com_shared/var/ppp/tmp:/var/ppp/tmp:delegated
      - ../pageperpage.com_shared/var/ppp/vantaca:/var/ppp/vantaca:delegated
    ports:
      - '801:80'
    networks:
      - ppp_network
  pppmysql:
    image: mysql:8
    container_name: pppmysql-container   
    environment:
      MYSQL_ROOT_PASSWORD: 123456#QxY
    ports:
      - "3308:3306"
    networks:
      - ppp_network
    restart: unless-stopped
    command: 
      --innodb_buffer_pool_size=8589934592
      --innodb_flush_log_at_trx_commit=0
      --max_allowed_packet=1073741824
      --innodb-flush-method=O_DIRECT 
      --innodb-use-native-aio=0
      --sql_mode=""
      --sync_binlog=0
      --skip-log-bin
    volumes:
      - ppp-mysql-data:/var/lib/mysql
      - ./dockerpppmysql/:/etc/mysql/conf.d:delegated

volumes:
  ppp-mysql-data:
    driver: local

networks:
  ppp_network:
    driver: bridge
