docker-compose.yml 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677
  1. version: "3.5"
  2. services:
  3. mysql:
  4. image: mariadb:latest
  5. volumes:
  6. - db-data:/var/lib/mysql
  7. - ./Docker/mysql/mysql.cnf:/etc/mysql/conf.d/custom.cnf:ro
  8. - "${DB_IMPORTE_FILE}:/docker-entrypoint-initdb.d/eql.sql"
  9. networks:
  10. - database
  11. environment:
  12. MYSQL_ROOT_PASSWORD: "${DB_ROOT_PASSWORD}"
  13. MYSQL_DATABASE: "${DB_NAME}"
  14. MYSQL_USER: "${DB_USERNAME}"
  15. MYSQL_PASSWORD: "${DB_PASSWORD}"
  16. redis:
  17. image: redis:6
  18. volumes:
  19. - redis-data:/data
  20. networks:
  21. - redis
  22. ports:
  23. - "6379"
  24. php:
  25. build: ./Docker/php-7.4-fpm/
  26. user: ${USER_UID}:${USER_GID}
  27. volumes:
  28. - php-user-data:/home/${USER_UNAME}
  29. - "${PROJECT_ROOT}:/var/www/d9"
  30. - "${LOG_ROOT}/php:/var/log:rw"
  31. - "${XDEBUG_INI}:/usr/local/etc/php/conf.d/xdebug.ini"
  32. working_dir: "/var/www/d9"
  33. networks:
  34. - database
  35. - redis
  36. - server
  37. depends_on:
  38. - mysql
  39. - redis
  40. phpmyadmin:
  41. image: phpmyadmin/phpmyadmin
  42. ports:
  43. - 8988:80
  44. networks:
  45. - database
  46. depends_on:
  47. - mysql
  48. environment:
  49. PMA_HOSTS: mysql
  50. nginx:
  51. build: ./Docker/nginx/
  52. ports:
  53. - 8987:80
  54. working_dir: "/var/www"
  55. volumes:
  56. - "${PROJECT_ROOT}:/var/www/d9"
  57. - "${LOG_ROOT}:/var/log:rw"
  58. networks:
  59. - server
  60. depends_on:
  61. - php
  62. volumes:
  63. db-data:
  64. redis-data:
  65. php-user-data:
  66. networks:
  67. database:
  68. redis:
  69. server: