12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970 |
- version: '3.8'
- # 网络
- networks:
- default:
- name: default-network
- external: true
- # 服务
- services:
- #nginx反向代理
- sku3d-nginx:
- image: "registry.cn-chengdu.aliyuncs.com/infish/pack-comm-nginx:1.23.1"
- restart: always
- ports:
- - 18081:80
- volumes:
- - ./nginx/conf.d:/etc/nginx/conf.d
- - ./nginx/www:/usr/share/nginx/html
- depends_on:
- - sku3d-usercenter
- # nats消息中间件
- sku3d-bus:
- restart: always
- image: registry.cn-chengdu.aliyuncs.com/infish/pack-comm-bus:v1.0.1
- volumes:
- - ./config-service.yaml:/root/bus/app.yaml
- depends_on:
- - sku3d-mongo
- - sku3d-redis
- ports:
- - 14223:4222
- # redis缓存
- sku3d-redis:
- image: "redis:alpine"
- restart: always
- command:
- --requirepass "packsku3d" #这一行是设置密码
- privileged: true
- ports:
- - 16379:6379
- # mongo数据库
- sku3d-mongo:
- image: mongo:4.4.1
- restart: always
- environment:
- MONGO_INITDB_ROOT_USERNAME: root
- MONGO_INITDB_ROOT_PASSWORD: root
- volumes:
- - ~/data/packs-sku3d/mongo/db:/data/db
- - ~/data/packs-sku3d/mongo/log:/var/log/mongodb
- ports:
- - 37018:27017
- #user服务
- sku3d-usercenter:
- image: registry.cn-chengdu.aliyuncs.com/infish/pack-comm-usercenter:v1.0.0
- restart: always
- depends_on:
- - sku3d-bus
- environment:
- NATS: nats://sku3d-bus:4222
-
|