|
|
|
@ -0,0 +1,48 @@
|
|
|
|
|
# Docker Compose 配置文件版本,这里使用 version 3
|
|
|
|
|
version: '3'
|
|
|
|
|
|
|
|
|
|
services:
|
|
|
|
|
interro-robot-paddlespeech:
|
|
|
|
|
image: interro-robot-paddlespeech:1.0.0
|
|
|
|
|
# 端口映射,将主机的某个端口映射到容器的 8089 端口
|
|
|
|
|
ports:
|
|
|
|
|
- 8089:8089
|
|
|
|
|
# 重启策略,如果容器退出则自动重启
|
|
|
|
|
restart: always
|
|
|
|
|
|
|
|
|
|
# interro-robot-qa 服务
|
|
|
|
|
interro-robot-qa:
|
|
|
|
|
image: interro-robot-qa:1.0.0
|
|
|
|
|
ports:
|
|
|
|
|
- 8000:8000
|
|
|
|
|
restart: always
|
|
|
|
|
|
|
|
|
|
# 第三个服务:interro-robot-web
|
|
|
|
|
interro-robot-web:
|
|
|
|
|
image: interro-robot-web:1.0.0
|
|
|
|
|
ports:
|
|
|
|
|
- 9800:9800
|
|
|
|
|
# 设置环境变量
|
|
|
|
|
environment:
|
|
|
|
|
- env.datasource.ip=192.168.10.138:5432
|
|
|
|
|
- env.datasource.username=postgres
|
|
|
|
|
- "env.datasource.password=123456"
|
|
|
|
|
- env.paddle-speech.ip=192.168.10.25:8089 # interro-robot-paddlespeech 服务地址
|
|
|
|
|
- env.match.ip=192.168.10.25:8000 #interro-robot-qa 服务地址
|
|
|
|
|
restart: always
|
|
|
|
|
|
|
|
|
|
# interro-robot-nginx 服务
|
|
|
|
|
interro-robot-nginx:
|
|
|
|
|
image: interro-robot-nginx:1.0.0
|
|
|
|
|
ports:
|
|
|
|
|
- 443:443
|
|
|
|
|
# 设置环境变量
|
|
|
|
|
environment:
|
|
|
|
|
# 设置后端服务地址
|
|
|
|
|
- UPSTREAM_WEB_SERVERS=192.168.10.25:9800
|
|
|
|
|
restart: always
|
|
|
|
|
|
|
|
|
|
# 使用 docker-compose up -d 命令启动所有服务
|
|
|
|
|
# 使用 docker-compose stop 命令停止服务
|
|
|
|
|
# 使用 docker-compose down 命令停止并删除所有服务
|
|
|
|
|
# 启动服务后,可通过 https:{ip}:443/#/login访问服务
|