text4u
您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

docker-compose.yml 922B

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. services:
  2. app:
  3. build:
  4. context: .
  5. dockerfile: Dockerfile
  6. image: sms-gateway-app
  7. container_name: sms-gateway-app
  8. restart: unless-stopped
  9. working_dir: /var/www
  10. volumes:
  11. - .:/var/www
  12. networks:
  13. - sms-gateway-network
  14. ports:
  15. - "9000:9000"
  16. webserver:
  17. image: nginx:alpine
  18. container_name: sms-gateway-webserver
  19. restart: unless-stopped
  20. ports:
  21. - "80:80"
  22. volumes:
  23. - .:/var/www
  24. - ./nginx.conf:/etc/nginx/conf.d/default.conf
  25. networks:
  26. - sms-gateway-network
  27. db:
  28. image: mysql:8.0
  29. container_name: sms-gateway-db
  30. restart: unless-stopped
  31. environment:
  32. MYSQL_DATABASE: sms-gateway
  33. MYSQL_ROOT_PASSWORD: root
  34. volumes:
  35. - db_data:/var/lib/mysql
  36. networks:
  37. - sms-gateway-network
  38. ports:
  39. - "3306:3306"
  40. networks:
  41. sms-gateway-network:
  42. driver: bridge
  43. volumes:
  44. db_data: