-
Notifications
You must be signed in to change notification settings - Fork 15
/
docker-compose.example.yml
43 lines (40 loc) · 992 Bytes
/
docker-compose.example.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
services:
redis:
image: redis:7-alpine
restart: always
env_file: .env
ports:
- "${REDIS_PORT}:${REDIS_PORT}"
expose:
- "${REDIS_PORT}"
volumes:
- redis-data:${REDIS_DATA}
command: [ "--requirepass", "${REDIS_PASSWORD}" ]
postgres:
image: postgres:16-alpine
restart: always
env_file: .env
environment:
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
POSTGRES_USER: ${POSTGRES_USER}
POSTGRES_DB: ${POSTGRES_DB}
PGDATA: ${POSTGRES_DATA}
ports:
- "${POSTGRES_PORT}:${POSTGRES_PORT}"
expose:
- "${POSTGRES_PORT}"
volumes:
- postgres-data:${POSTGRES_DATA}
bot:
build: .
restart: always
env_file: .env
depends_on:
- redis
- postgres
ports:
- "${SERVER_PORT}:${SERVER_PORT}"
entrypoint: [ "/app/scripts/run-bot.sh" ]
volumes:
redis-data:
postgres-data: