version: '3'
services:

#  rabbitmq:
#    image: rabbitmq:management
#    ports:
#      - 5672:5672
#      - 15672:15672
#    networks:
#      - my-network

  # kafka:
  #   container_name: kafka
  #   image: spotify/kafka:latest
  #   ports:
  #    - 2181:2181
  #    - 9092:9092
  #   networks:
  #     - my-network

#  zipkin:
#    image: openzipkin/zipkin
#    ports:
#      - 9411:9411
#    networks:
#      - my-network

  redis:
    image: redis
    ports:
      - 6379:6379
    networks:
      - my-network

  ts-ui-dashboard:
    image: codewisdom/ts-ui-dashboard-with-jaeger:v1
    restart: always
    ports:
      - 8080:8080
    networks:
      - my-network

  ts-auth-service:
    image: codewisdom/ts-auth-service-with-jaeger:v1
    restart: always
    ports:
      - 12340:12340
    networks:
      - my-network

  ts-auth-mysql:
    image: mysql:5.7
    networks:
      - my-network

  ts-user-service:
    image: codewisdom/ts-user-service-with-jaeger:v1
    restart: always
    ports:
      - 12342:12342
    networks:
      - my-network

  ts-user-mysql:
    image: mysql:5.7
    networks:
      - my-network

  ts-verification-code-service:
    image: codewisdom/ts-verification-code-service-with-jaeger:v1
    restart: always
    ports:
      - 15678:15678
    networks:
      - my-network


#  ts-account-mongo:
#    image: mongo
#    networks:
#      - my-network

  ts-route-service:
    image: codewisdom/ts-route-service-with-jaeger:v1
    restart: always
    ports:
         - 11178:11178
    networks:
      - my-network

  ts-route-mysql:
    image: mysql:5.7
    networks:
        - my-network

  ts-contacts-service:
    image: codewisdom/ts-contacts-service-with-jaeger:v1
    restart: always
    ports:
      - 12347:12347
    networks:
      - my-network

  ts-contacts-mysql:
      image: mysql:5.7
      networks:
        - my-network

  ts-order-service:
    image: codewisdom/ts-order-service-with-jaeger:v1
    restart: always
    ports:
      - 12031:12031
    networks:
      - my-network

  ts-order-mysql:
    image: mysql:5.7
    networks:
      - my-network


  ts-order-other-service:
    image: codewisdom/ts-order-other-service-with-jaeger:v1
    restart: always
    ports:
      - 12032:12032
    networks:
      - my-network

  ts-order-other-mysql:
    image: mysql:5.7
    networks:
      - my-network


  ts-config-service:
    image: codewisdom/ts-config-service-with-jaeger:v1
    restart: always
    ports:
      - 15679:15679
    networks:
      - my-network

  ts-config-mysql:
    image: mysql:5.7
    networks:
      - my-network

  ts-station-service:
    image: codewisdom/ts-station-service-with-jaeger:v1
    restart: always
    ports:
      - 12345:12345
    networks:
      - my-network

  ts-station-mysql:
    image: mysql:5.7
    networks:
      - my-network

  ts-train-service:
    image: codewisdom/ts-train-service-with-jaeger:v1
    restart: always
    ports:
      - 14567:14567
    networks:
      - my-network

  ts-train-mysql:
    image: mysql:5.7
    networks:
      - my-network

  ts-travel-service:
    image: codewisdom/ts-travel-service-with-jaeger:v1
    restart: always
    ports:
      - 12346:12346
    networks:
      - my-network

  ts-travel-mysql:
    image: mysql:5.7
    networks:
      - my-network

  ts-travel2-service:
      image: codewisdom/ts-travel2-service-with-jaeger:v1
      restart: always
      ports:
        - 16346:16346
      networks:
        - my-network

  ts-travel2-mysql:
      image: mysql:5.7
      networks:
        - my-network

  ts-preserve-service:
    image: codewisdom/ts-preserve-service-with-jaeger:v1
    restart: always
    ports:
      - 14568:14568
    networks:
      - my-network

  ts-preserve-other-service:
    image: codewisdom/ts-preserve-other-service-with-jaeger:v1
    restart: always
    ports:
      - 14569:14569
    networks:
      - my-network


  ts-basic-service:
      image: codewisdom/ts-basic-service-with-jaeger:v1
      restart: always
      ports:
        - 15680:15680
      networks:
          - my-network

#  ts-ticketinfo-service:
#        image: codewisdom/ts-ticketinfo-service-with-jaeger:v1
#        restart: always
#        ports:
#          - 15681:15681
#        networks:
#          - my-network

  ts-price-service:
        image: codewisdom/ts-price-service-with-jaeger:v1
        restart: always
        ports:
          - 16579:16579
        networks:
          - my-network

  ts-price-mysql:
        image: mysql:5.7
        networks:
          - my-network

  ts-notification-service:
        image: codewisdom/ts-notification-service-with-jaeger:v1
        restart: always
        ports:
          - 17853:17853
        networks:
          - my-network

  ts-notification-mysql:
    image: mysql:5.7
    networks:
      - my-network

  ts-security-service:
        image: codewisdom/ts-security-service-with-jaeger:v1
        restart: always
        ports:
          - 11188:11188
        networks:
          - my-network

  ts-security-mysql:
        image: mysql:5.7
        networks:
          - my-network

  ts-inside-payment-service:
        image: codewisdom/ts-inside-payment-service-with-jaeger:v1
        restart: always
        ports:
          - 18673:18673
        networks:
          - my-network

  ts-inside-payment-mysql:
        image: mysql:5.7
        networks:
          - my-network

  ts-execute-service:
        image: codewisdom/ts-execute-service-with-jaeger:v1
        restart: always
        ports:
          - 12386:12386
        networks:
          - my-network

  ts-payment-service:
        image: codewisdom/ts-payment-service-with-jaeger:v1
        restart: always
        ports:
          - 19001:19001
        networks:
          - my-network

  ts-payment-mysql:
        image: mysql:5.7
        networks:
          - my-network

  ts-rebook-service:
        image: codewisdom/ts-rebook-service-with-jaeger:v1
        restart: always
        ports:
          - 18886:18886
        networks:
          - my-network

  ts-rebook-mysql:
        image: mysql:5.7
        networks:
          - my-network

  ts-cancel-service:
        image: codewisdom/ts-cancel-service-with-jaeger:v1
        restart: always
        ports:
          - 18885:18885
        networks:
          - my-network

  ts-assurance-service:
        image: codewisdom/ts-assurance-service-with-jaeger:v1
        restart: always
        ports:
          - 18888:18888
        networks:
          - my-network

  ts-assurance-mysql:
        image: mysql:5.7
        networks:
          - my-network

  ts-seat-service:
        image: codewisdom/ts-seat-service-with-jaeger:v1
        restart: always
        ports:
          - 18898:18898
        networks:
          - my-network

  ts-travel-plan-service:
        image: codewisdom/ts-travel-plan-service-with-jaeger:v1
        restart: always
        ports:
          - 14322:14322
        networks:
          - my-network

#  ts-ticket-office-service:
#        image: codewisdom/ts-ticket-office-service-with-jaeger:v1
#        restart: always
#        ports:
#          - 16108:16108
#        networks:
#          - my-network
#
#  ts-ticket-office-mongo:
#          image: mongo
#          networks:
#            - my-network

  ts-news-service:
    image: codewisdom/ts-news-service-with-jaeger:v1
    restart: always
    ports:
      - 12862:12862
    networks:
      - my-network

  ts-news-mysql:
        image: mysql:5.7
        networks:
          - my-network

  ts-voucher-mysql:
         image: mysql
         expose:
            - "3306"
         environment:
           MYSQL_ROOT_PASSWORD: root
         networks:
           - my-network

  ts-voucher-service:
          image: codewisdom/ts-voucher-service-with-jaeger:v1
          restart: always
          ports:
            - 16101:16101
          depends_on:
            - ts-voucher-mysql
          volumes:
            - /var/lib/mysql
          networks:
            - my-network

#  ts-food-map-service:
#        image: codewisdom/ts-food-map-service-with-jaeger:v1
#        restart: always
#        ports:
#          - 18855:18855
#        networks:
#          - my-network
#
#  ts-food-map-mongo:
#          image: mongo
#          networks:
#            - my-network

  ts-route-plan-service:
          image: codewisdom/ts-route-plan-service-with-jaeger:v1
          restart: always
          ports:
            - 14578:14578
          networks:
            - my-network

  ts-food-service:
      image: codewisdom/ts-food-service-with-jaeger:v1
      restart: always
      ports:
        - 18856:18856
      networks:
        - my-network


  ts-food-mysql:
    image: mysql:5.7
    networks:
      - my-network

  ts-consign-service:
            image: codewisdom/ts-consign-service-with-jaeger:v1
            restart: always
            ports:
              - 16111:16111
            networks:
              - my-network

  ts-consign-mysql:
            image: mysql:5.7
            networks:
              - my-network

  ts-consign-price-service:
            image: codewisdom/ts-consign-price-service-with-jaeger:v1
            restart: always
            ports:
              - 16110:16110
            networks:
              - my-network

  ts-consign-price-mysql:
            image: mysql:5.7
            networks:
              - my-network


  ts-admin-basic-info-service:
        image: codewisdom/ts-admin-basic-info-service-with-jaeger:v1
        restart: always
        ports:
          - 18767:18767
        networks:
          - my-network

  ts-admin-order-service:
            image: codewisdom/ts-admin-order-service-with-jaeger:v1
            restart: always
            ports:
              - 16112:16112
            networks:
              - my-network

  ts-admin-route-service:
              image: codewisdom/ts-admin-route-service-with-jaeger:v1
              restart: always
              ports:
                - 16113:16113
              deploy:
                replicas: 1
                restart_policy:
                  condition: on-failure
              networks:
                - my-network

  ts-admin-travel-service:
                image: codewisdom/ts-admin-travel-service-with-jaeger:v1
                restart: always
                ports:
                  - 16114:16114
                deploy:
                  replicas: 1
                  restart_policy:
                    condition: on-failure
                networks:
                  - my-network

  ts-admin-user-service:
    image: codewisdom/ts-admin-user-service-with-jaeger:v1
    restart: always
    ports:
      - 16115:16115
    deploy:
      replicas: 1
      restart_policy:
        condition: on-failure
    networks:
      - my-network

  ts-avatar-service:
    image: codewisdom/ts-avatar-service-with-jaeger:v1
    restart: always
    ports:
      - 17001:17001
    networks:
      - my-network


  ts-delivery-service:
    image: ${NAMESPACE}/ts-delivery-servicee-with-jaeger:v1
    restart: always
    ports:
      - 18808:18808
    networks:
      - my-network

  ts-delivery-mysql:
    image: mysql:5.7
    networks:
      - my-network


  ts-food-delivery-service:
    image: ${NAMESPACE}/ts-food-delivery-service-with-jaeger:v1
    restart: always
    ports:
      - 18957:18957
    networks:
      - my-network

  ts-food-delivery-mysql:
    image: mysql:5.7
    networks:
      - my-network


  ts-gateway-service:
    image: ${NAMESPACE}/ts-gateway-service-with-jaeger:v1
    restart: always
    ports:
      - 18888:18888
    networks:
      - my-network

  ts-gateway-mysql:
    image: mysql:5.7
    networks:
      - my-network

  ts-station-food-service:
    image: ${NAMESPACE}/ts-station-food-service-with-jaeger:v1
    restart: always
    ports:
      - 18855:18855
    networks:
      - my-network

  ts-station-food-mysql:
    image: mysql:5.7
    networks:
      - my-network

  ts-train-food-service:
    image: ${NAMESPACE}/ts-train-food-service-with-jaeger:v1
    restart: always
    ports:
      - 19999:19999
    networks:
      - my-network

  ts-train-food-mysql:
    image: mysql:5.7
    networks:
      - my-network


  jaeger:
    image: jaegertracing/all-in-one:1.15
    ports:
      - 16686:16686
    deploy:
      replicas: 1
      restart_policy:
        condition: on-failure
    networks:
      - my-network


networks:
    my-network:
      # driver: overlay
      driver: bridge





