编辑 docker-compose.yml

    1. #注意mysql数据库版本最好是5.6-5.7的,我用mysql8.0连接不成功
    2. version: '2'
    3. services:
    4. # The zipkin process services the UI, and also exposes a POST endpoint that
    5. # instrumentation can send trace data to. Scribe is disabled by default.
    6. zipkin:
    7. image: 10.10.0.110/box/zipkin:latest
    8. container_name: zipkin
    9. environment:
    10. - STORAGE_TYPE=mysql
    11. # Point the zipkin at the storage backend
    12. - MYSQL_DB=mws_zipkin
    13. - MYSQL_USER=root
    14. - MYSQL_PASS=benwunetJ!@#
    15. - MYSQL_HOST=49.4.6.180
    16. - MYSQL_TCP_PORT=3306
    17. # Uncomment to enable scribe
    18. # - SCRIBE_ENABLED=true
    19. # Uncomment to enable self-tracing
    20. # - SELF_TRACING_ENABLED=true
    21. # Uncomment to enable debug logging
    22. # - JAVA_OPTS=-Dlogging.level.zipkin=DEBUG -Dlogging.level.zipkin2=DEBUG
    23. network_mode: host
    24. ports:
    25. # Port used for the Zipkin UI and HTTP Api
    26. - 9411:9411
    27. # Uncomment if you set SCRIBE_ENABLED=true
    28. # - 9410:9410
    29. #networks:
    30. # - default
    31. # - my_net #创建网路 docker network create my_net 删除网络 docker network rm my_net
    32. #networks:
    33. #my_net:
    34. #external: true