version: '3.8' # 网络 networks: default: name: default-network external: true services: #nginx反向代理 3dshow-nginx-alpha: image: "registry.cn-chengdu.aliyuncs.com/infish/pack-comm-nginx:1.23.1" restart: always ports: - 18095:80 volumes: - ./nginx/conf.d:/etc/nginx/conf.d - ./nginx/www:/usr/share/nginx/html depends_on: - 3dshow-customer-alpha - 3dshow-supplier-alpha - 3dshow-supply-user-alpha - 3dshow-customer-user-alpha #bus消息中间件 3dshow-bus-alpha: restart: always image: registry.cn-chengdu.aliyuncs.com/infish/pack-comm-bus:v1.0.0 volumes: - ./config-service.yaml:/root/bus/app.yaml depends_on: - 3dshow-mongo-alpha - 3dshow-redis-alpha ports: - 14306:4222 #redis缓存 3dshow-redis-alpha: image: "redis:alpine" restart: always command: --requirepass "3dshow" #这一行是设置密码 privileged: true ports: - 16395:6379 #mongo 数据库 3dshow customer-user supply-user 3dshow-mongo-alpha: image: mongo:4.4.1 restart: always environment: MONGO_INITDB_ROOT_USERNAME: root MONGO_INITDB_ROOT_PASSWORD: 3dshow volumes: - ~/data/packs-3dshow-alpha/mongo/db:/data/db - ~/data/packs-3dshow-alpha/mongo/log:/var/log/mongodb ports: - 37038:27017 # 3dshow customer 3dshow-customer-alpha: image: registry.cn-chengdu.aliyuncs.com/infish/pack-3dshow-customer:v1.0.0 restart: always depends_on: - 3dshow-bus-alpha environment: NATS: nats://3dshow-bus-alpha:4222 # 3dshow supplier 3dshow-supplier-alpha: image: registry.cn-chengdu.aliyuncs.com/infish/pack-3dshow-supplier:v1.0.0 restart: always depends_on: - 3dshow-bus-alpha environment: NATS: nats://3dshow-bus-alpha:4222 # user服务 3dshow-supply-user-alpha: image: registry.cn-chengdu.aliyuncs.com/infish/pack-comm-usercenter:v1.0.0 restart: always depends_on: - 3dshow-bus-alpha environment: NATS: nats://3dshow-bus-alpha:4222 CONFIGER_MONGO: 3dshow-supply-user-mongo CONFIGER_REDIS: 3dshow-redis CONFIGER_JWT: spu3d#spu3d secret#168 # MONGO_MIGRATIONS: /data/migrations==mongodb://root:3dshow@3dshow-mongo-alpha:27017/supply-user?authSource=admin&&/data/migrations==mongodb://user:password@host:port/dbname?query MONGO_MIGRATIONS: /data/migrations==mongodb://root:3dshow@3dshow-mongo-alpha:27017/supply-user?authSource=admin volumes: - ./mongo-migrations/supplier:/data/migrations # c端用户 3dshow-customer-user-alpha: image: registry.cn-chengdu.aliyuncs.com/infish/pack-comm-usercenter:v1.0.0 restart: always depends_on: - 3dshow-bus-alpha environment: NATS: nats://3dshow-bus-alpha:4222 CONFIGER_MONGO: 3dshow-customer-user-mongo CONFIGER_REDIS: 3dshow-redis CONFIGER_JWT: spu3d#spu3d secret#168 MONGO_MIGRATIONS: /data/migrations==mongodb://root:3dshow@3dshow-mongo-alpha:27017/customer-user?authSource=admin volumes: - ./mongo-migrations/customer:/data/migrations