jenkins-pipeline-files/compose-file/python-docker-compose.yml
2026-01-14 21:31:13 +08:00

330 lines
9.3 KiB
YAML

version: '3.7'
# 应用服务
services:
# 网关服务
django_layui:
# 镜像名称
image: ${DOCKER_REGISTRY_URL}/djangoadmin/${SERVER_NAME}:${VERSION:-latest}
# 容器名称
container_name: ${SERVER_NAME}
#build: .
# 将容器运行在特权模式下,意味着容器内的进程将具
# 有访问宿主机的权限,包括文件系统、设备和系统功能等
privileged: true
# 指定容器中运行的用户
user: root
# 启动策略为始终重启
restart: always
# 设置网络模式为host模式
network_mode: host
# 端口映射
ports:
- 8010:8010
# 文件挂载
volumes:
- $PWD/${SERVER_NAME}/uploads:/data/apps/uploads
# 日志配置
logging:
driver: "json-file"
options:
max-size: "500m"
max-file: "10"
# 后端服务
django_elevue:
# 镜像名称
image: ${DOCKER_REGISTRY_URL}/djangoadmin/${SERVER_NAME}:${VERSION:-latest}
# 容器名称
container_name: ${SERVER_NAME}
# 将容器运行在特权模式下,意味着容器内的进程将具
# 有访问宿主机的权限,包括文件系统、设备和系统功能等
privileged: true
# 指定容器中运行的用户
user: root
# 启动策略为始终重启
restart: always
# 设置网络模式为host模式
network_mode: host
# 端口映射
ports:
- 8013:8013
# 文件挂载
volumes:
- $PWD/${SERVER_NAME}/uploads:/data/apps/uploads
# 日志配置
logging:
driver: "json-file"
options:
max-size: "500m"
max-file: "10"
# 后端服务
django_antdvue:
# 镜像名称
image: ${DOCKER_REGISTRY_URL}/djangoadmin/${SERVER_NAME}:${VERSION:-latest}
# 容器名称
container_name: ${SERVER_NAME}
# 将容器运行在特权模式下,意味着容器内的进程将具
# 有访问宿主机的权限,包括文件系统、设备和系统功能等
privileged: true
# 指定容器中运行的用户
user: root
# 启动策略为始终重启
restart: always
# 设置网络模式为host模式
network_mode: host
# 端口映射
ports:
- 8016:8016
# 文件挂载
volumes:
- $PWD/${SERVER_NAME}/uploads:/data/apps/uploads
# 日志配置
logging:
driver: "json-file"
options:
max-size: "500m"
max-file: "10"
# 网关服务
flask_layui:
# 镜像名称
image: ${DOCKER_REGISTRY_URL}/djangoadmin/${SERVER_NAME}:${VERSION:-latest}
# 容器名称
container_name: ${SERVER_NAME}
# 将容器运行在特权模式下,意味着容器内的进程将具
# 有访问宿主机的权限,包括文件系统、设备和系统功能等
privileged: true
# 指定容器中运行的用户
user: root
# 启动策略为始终重启
restart: always
# 设置网络模式为host模式
network_mode: host
# 端口映射
ports:
- 8020:8020
# 文件挂载
volumes:
- $PWD/${SERVER_NAME}/uploads:/data/apps/uploads
# 日志配置
logging:
driver: "json-file"
options:
max-size: "500m"
max-file: "10"
# 后端服务
flask_elevue:
# 镜像名称
image: ${DOCKER_REGISTRY_URL}/djangoadmin/${SERVER_NAME}:${VERSION:-latest}
# 容器名称
container_name: ${SERVER_NAME}
# 将容器运行在特权模式下,意味着容器内的进程将具
# 有访问宿主机的权限,包括文件系统、设备和系统功能等
privileged: true
# 指定容器中运行的用户
user: root
# 启动策略为始终重启
restart: always
# 设置网络模式为host模式
network_mode: host
# 端口映射
ports:
- 8023:8023
# 文件挂载
volumes:
- $PWD/${SERVER_NAME}/uploads:/data/apps/uploads
# 日志配置
logging:
driver: "json-file"
options:
max-size: "500m"
max-file: "10"
# 后端服务
flask_antdvue:
# 镜像名称
image: ${DOCKER_REGISTRY_URL}/djangoadmin/${SERVER_NAME}:${VERSION:-latest}
# 容器名称
container_name: ${SERVER_NAME}
# 将容器运行在特权模式下,意味着容器内的进程将具
# 有访问宿主机的权限,包括文件系统、设备和系统功能等
privileged: true
# 指定容器中运行的用户
user: root
# 启动策略为始终重启
restart: always
# 设置网络模式为host模式
network_mode: host
# 端口映射
ports:
- 8026:8026
# 文件挂载
volumes:
- $PWD/${SERVER_NAME}/uploads:/data/apps/uploads
# 日志配置
logging:
driver: "json-file"
options:
max-size: "500m"
max-file: "10"
# 应用服务
fastapi_layui:
# 镜像名称
image: ${DOCKER_REGISTRY_URL}/djangoadmin/${SERVER_NAME}:${VERSION:-latest}
# 容器名称
container_name: ${SERVER_NAME}
# 将容器运行在特权模式下,意味着容器内的进程将具
# 有访问宿主机的权限,包括文件系统、设备和系统功能等
privileged: true
# 指定容器中运行的用户
user: root
# 启动策略为始终重启
restart: always
# 设置网络模式为host模式
network_mode: host
# 端口映射
ports:
- 8030:8030
# 文件挂载
volumes:
- $PWD/${SERVER_NAME}/uploads:/data/apps/uploads
# 日志配置
logging:
driver: "json-file"
options:
max-size: "500m"
max-file: "10"
# 后端服务
fastapi_elevue:
# 镜像名称
image: ${DOCKER_REGISTRY_URL}/djangoadmin/${SERVER_NAME}:${VERSION:-latest}
# 容器名称
container_name: ${SERVER_NAME}
# 将容器运行在特权模式下,意味着容器内的进程将具
# 有访问宿主机的权限,包括文件系统、设备和系统功能等
privileged: true
# 指定容器中运行的用户
user: root
# 启动策略为始终重启
restart: always
# 设置网络模式为host模式
network_mode: host
# 端口映射
ports:
- 8033:8033
# 文件挂载
volumes:
- $PWD/${SERVER_NAME}/uploads:/data/apps/uploads
# 日志配置
logging:
driver: "json-file"
options:
max-size: "500m"
max-file: "10"
# 后端服务
fastapi_antdvue:
# 镜像名称
image: ${DOCKER_REGISTRY_URL}/djangoadmin/${SERVER_NAME}:${VERSION:-latest}
# 容器名称
container_name: ${SERVER_NAME}
# 将容器运行在特权模式下,意味着容器内的进程将具
# 有访问宿主机的权限,包括文件系统、设备和系统功能等
privileged: true
# 指定容器中运行的用户
user: root
# 启动策略为始终重启
restart: always
# 设置网络模式为host模式
network_mode: host
# 端口映射
ports:
- 8036:8036
# 文件挂载
volumes:
- $PWD/${SERVER_NAME}/uploads:/data/apps/uploads
# 日志配置
logging:
driver: "json-file"
options:
max-size: "500m"
max-file: "10"
# 应用服务
tornado_layui:
# 镜像名称
image: ${DOCKER_REGISTRY_URL}/djangoadmin/${SERVER_NAME}:${VERSION:-latest}
# 容器名称
container_name: ${SERVER_NAME}
# 将容器运行在特权模式下,意味着容器内的进程将具
# 有访问宿主机的权限,包括文件系统、设备和系统功能等
privileged: true
# 指定容器中运行的用户
user: root
# 启动策略为始终重启
restart: always
# 设置网络模式为host模式
network_mode: host
# 端口映射
ports:
- 8040:8040
# 文件挂载
volumes:
- $PWD/${SERVER_NAME}/uploads:/data/apps/uploads
# 日志配置
logging:
driver: "json-file"
options:
max-size: "500m"
max-file: "10"
# 后端服务
tornado_elevue:
# 镜像名称
image: ${DOCKER_REGISTRY_URL}/djangoadmin/${SERVER_NAME}:${VERSION:-latest}
# 容器名称
container_name: ${SERVER_NAME}
# 将容器运行在特权模式下,意味着容器内的进程将具
# 有访问宿主机的权限,包括文件系统、设备和系统功能等
privileged: true
# 指定容器中运行的用户
user: root
# 启动策略为始终重启
restart: always
# 设置网络模式为host模式
network_mode: host
# 端口映射
ports:
- 8043:8043
# 文件挂载
volumes:
- $PWD/${SERVER_NAME}/uploads:/data/apps/uploads
# 日志配置
logging:
driver: "json-file"
options:
max-size: "500m"
max-file: "10"
# 后端服务
tornado_antdvue:
# 镜像名称
image: ${DOCKER_REGISTRY_URL}/djangoadmin/${SERVER_NAME}:${VERSION:-latest}
# 容器名称
container_name: ${SERVER_NAME}
# 将容器运行在特权模式下,意味着容器内的进程将具
# 有访问宿主机的权限,包括文件系统、设备和系统功能等
privileged: true
# 指定容器中运行的用户
user: root
# 启动策略为始终重启
restart: always
# 设置网络模式为host模式
network_mode: host
# 端口映射
ports:
- 8046:8046
# 文件挂载
volumes:
- $PWD/${SERVER_NAME}/uploads:/data/apps/uploads
# 日志配置
logging:
driver: "json-file"
options:
max-size: "500m"
max-file: "10"