mirror of
https://github.com/tiennm99/gomoku.git
synced 2026-05-31 00:21:52 +00:00
6e3670aec8
Import source files from ratel-online organization repos into monorepo structure for gomoku game development. Update README with project structure and credits for original authors.
47 lines
1.0 KiB
YAML
47 lines
1.0 KiB
YAML
version: '3.8'
|
|
|
|
services:
|
|
ratel-server:
|
|
build:
|
|
context: .
|
|
dockerfile: Dockerfile
|
|
image: ratel-server:latest
|
|
container_name: ratel-server
|
|
restart: unless-stopped
|
|
ports:
|
|
- "9998:9998" # WebSocket端口
|
|
- "9999:9999" # TCP端口
|
|
environment:
|
|
- TZ=Asia/Shanghai
|
|
# volumes:
|
|
# # 如果需要持久化日志,可以取消下面的注释
|
|
# - ./logs:/app/logs
|
|
networks:
|
|
- ratel-network
|
|
command: ["./ratel-server", "-w", "9998", "-t", "9999"]
|
|
healthcheck:
|
|
test: ["CMD", "nc", "-z", "localhost", "9998"]
|
|
interval: 30s
|
|
timeout: 3s
|
|
retries: 3
|
|
start_period: 10s
|
|
logging:
|
|
driver: "json-file"
|
|
options:
|
|
max-size: "10m"
|
|
max-file: "3"
|
|
deploy:
|
|
resources:
|
|
limits:
|
|
cpus: '2'
|
|
memory: 512M
|
|
reservations:
|
|
cpus: '0.5'
|
|
memory: 128M
|
|
|
|
networks:
|
|
ratel-network:
|
|
driver: bridge
|
|
ipam:
|
|
config:
|
|
- subnet: 172.20.0.0/16 |