forked from cscs181/QQ-GitHub-Bot
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
43 lines (43 loc) · 1017 Bytes
/
docker-compose.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
version: "2"
services:
redis:
image: redis:6.2
container_name: bot_redis
command: redis-server --appendonly yes
volumes:
- bot_redis_data:/data
networks:
- bot_net
restart: always
nonebot:
image: cscs181/qq-github-bot:latest # docker hub
# image: ghcr.io/cscs181/qq-github-bot:latest # github image mirror
# build: . # use "build" instead of "image" if you want to build the image yourself
container_name: bot
# volumes:
# - "/etc/timezone:/etc/timezone:ro"
# - "/etc/localtime:/etc/localtime:ro"
ports:
- "$PORT:$PORT"
# you can load config file by "env_file"
env_file:
- "./.env"
environment:
- ENVIRONMENT=prod
- HOST=$HOST
- PORT=$PORT
- REDIS_HOST=bot_redis
- REDIS_PORT=6379
networks:
- bot_net
links:
- redis
depends_on:
- redis
restart: always
mem_limit: 1024M
mem_reservation: 512M
networks:
bot_net: {}
volumes:
bot_redis_data: {}