docker-compose.yml 659 B

123456789101112131415161718192021222324252627282930
  1. version: "2.1"
  2. services:
  3. mysql:
  4. image: daocloud.io/mysql:5.7.4
  5. volumes:
  6. - /var/lib/docker/db_data:/var/lib/mysql
  7. restart: always
  8. environment:
  9. MYSQL_ROOT_PASSWORD: somewordpress
  10. MYSQL_DATABASE: wordpress
  11. MYSQL_USER: wordpress
  12. MYSQL_PASSWORD: 123456
  13. discuz:
  14. image: discuz:4.3x
  15. ports:
  16. - 8080:80
  17. wordpress:
  18. depends_on:
  19. - db
  20. image: daocloud.io/library/wordpress:4.2.1-apache
  21. volumes:
  22. - /data/web_data:/var/www/html
  23. ports:
  24. - "8080:80"
  25. restart: always
  26. environment:
  27. WORDPRESS_DB_HOST: db:3306
  28. WORDPRESS_DB_USER: wordpress
  29. WORDPRESS_DB_PASSWORD: 123456