services:
  myphp:
    image: gathan1979/aianos_php_ext:1.3.16
    networks:
      - backend
    environment:
      - TZ=Europe/Athens
    volumes:
      - ./sigUploads:/var/www/html/api/sigUploads
      - ./protocolFiles:/var/www/html/api/protocolFiles
#      - ./php_ext/api:/var/www/html/api
#      - ./php_ext/mail:/var/www/html/mail
#      - ./php_ext/admin:/var/www/html/admin
#      - ./php_ext/:/var/www/
#      - ./php_ext/connectionAdeies.php:/var/www/html/connectionAdeies.php
#      - ./php_ext/connectionProtocol.php:/var/www/html/connectionProtocol.php
#      - ./php_ext/connectionAdeiesPDO.php:/var/www/html/connectionAdeiesPDO.php
      - e:\digitalSignature:/var/www/html/api/secondary  
    ports:
      - "587:587"
      - "993:993"
  myapache:
    image: gathan1979/aianos_httpd_ext:1.3.14
    depends_on:
      - myphp
      - mymysql
    networks:
      - frontend
      - backend
    ports:
      - "80:80"
      - "443:443"
    volumes:
#      - ./apache/directorSign:/var/www/html/directorSign
#      - ./apache/admin:/var/www/html/admin
#      - ./apache/mail:/var/www/html/mail
      - ./qrcodes:/var/www/html/qrcodes
  mymysql:
    image: mariadb:11.3
    networks:
      - backend
    ports:
      - "3306:3306"
    environment:
      - MARIADB_ROOT_PASSWORD=root
      - TZ=Europe/Athens
    volumes:
      - ./db_data:/var/lib/mysql
      - ./db_initialize:/docker-entrypoint-initdb.d
 #     - ./db_import_data:/tmp
    healthcheck:
      test: ["CMD", "mariadb-admin", "ping", "-h", "127.0.0.1", "-proot", "--silent"]
      interval: 5s
      retries: 20
  myliquibase:
    depends_on:
       mymysql:
          condition: service_healthy
    image: gathan1979/aianos_liquibase:1.0.13
    networks:
      - backend
#    volumes:
#      - ./db_liquibase:/liquibase/changelog
  mybackup:
    depends_on:
       mymysql:
          condition: service_healthy
    image: gathan1979/aianos_phpmyadmin:1.0.1
    networks:
      - backend
    ports:
      - "8080:80"
    environment:
      - MARIADB_ROOT_PASSWORD=root
      - PMA_HOST=mymysql
#    volumes:
#      - ./db_liquibase:/liquibase/changelog
networks:
    frontend:
    backend: