代码拉取完成,页面将自动刷新
# 指定版本号
"version": "3"
# 服务,表示要启动的容器服务
"services":
# 每个服务的名字就是容器的名字
redis:
image: redis:alpine
restart: always
volumes:
- /mydata/redis/data:/data
- /mydata/redis/conf/redis.conf:/etc/redis/redis.conf
command: redis-server /etc/redis/redis.conf
mariadb:
image: mariadb:latest
restart: always
environment:
MARIADB_ROOT_PASSWORD: pythonvip
MARIADB_DATABASE: HRUN
volumes:
- mariadb:/var/lib/mysql
ports:
- "8000:3306"
backend:
depends_on:
- redis
- mariadb
build: ./backend
image: backend_django_image
environment:
ENV: production
restart: always
volumes:
- app_logs:/app/logs
ports:
- "3306:3306"
nginx:
depends_on:
- backend
build: ./nginx
image: backend_nginx_image
ports:
- "5001:80"
- "5002:81"
volumes:
- nginx_logs:/var/log
volumes:
mariadb:
app_logs:
nginx_logs:
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。