1 Star 4 Fork 0

BluesYoung-web / young-chat-server

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
docker-compose.yml 1.28 KB
一键复制 编辑 原始数据 按行查看 历史
BluesYoung-web 提交于 2021-10-17 15:11 . chore: :hammer:配置调整
# docker-compose 配置文件
version: '3.3'
services:
mariadb:
image: jsurf/rpi-mariadb
ports: ['3306:3306']
volumes:
- /home/pi/data-base/data:/var/lib/mysql
- /home/pi/data-base/initdb.d:/docker-entrypoint-initdb.d
environment:
MYSQL_ROOT_PASSWORD: 'my-secret-pw'
restart: always
networks:
web-net:
ipv4_address: 172.18.0.4
redis:
image: redis
ports: ['6379:6379']
restart: always
networks:
web-net:
ipv4_address: 172.18.0.5
node-server-chat:
image: node
volumes:
- /home/pi/node-server/chat:/home/node
restart: always
depends_on:
- mariadb
- redis
networks:
web-net:
ipv4_address: 172.18.0.6
command: /bin/bash -c "cd /home/node && yarn && node main.js"
nginx-server:
image: nginx
# 外部:内部
ports: ['8080:80']
volumes:
- /home/pi/www/.nginx/nginx.conf:/etc/nginx/nginx.conf
- /home/pi/www:/etc/nginx/html
restart: always
depends_on:
- node-server-chat
networks:
web-net:
ipv4_address: 172.18.0.2
networks: ##定义网络组
web-net: ## 网络组名称
driver: bridge ## 网络的模式
ipam: ## 配置网络
driver: default
config:
- subnet: 172.18.0.0/24
TypeScript
1
https://gitee.com/BluesYoung-web/young-chat-server.git
git@gitee.com:BluesYoung-web/young-chat-server.git
BluesYoung-web
young-chat-server
young-chat-server
master

搜索帮助