docker-compose.yml 780 B

123456789101112131415161718192021222324252627282930
  1. version: '3'
  2. services:
  3. mariadb:
  4. image: mariadb:latest
  5. container_name: mariadb
  6. restart: always
  7. env_file:
  8. - ".env"
  9. command: [
  10. '--wait_timeout=360000'
  11. ]
  12. environment:
  13. - MARIADB_DATABASE=mysql
  14. - MARIADB_ROOT_USER=${MARIADB_ROOT_USER}
  15. - MARIADB_ROOT_PASSWORD=${MARIADB_ROOT_PASSWORD}
  16. - MARIADB_ALLOW_EMPTY_PASSWORD=no
  17. - MARIADB_USER=${MARIADB_USER}
  18. - MARIADB_PASSWORD=${MARIADB_PASS}
  19. ports:
  20. - "0.0.0.0:3306:3306"
  21. volumes:
  22. - ./server/inc/databases:/var/lib/mysql
  23. - ./server/inc/my.cnf:/etc/mysql/my.cnf:ro
  24. - ./server/inc/innodb.cnf:/etc/mysql/conf.d/innodb.cnf:ro
  25. networks: # Required for connectivity with separate docker-compose web framework
  26. default:
  27. name: database