-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
38 lines (38 loc) · 983 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
version: "3.9"
services:
postgres:
image: "postgres:16-alpine3.18"
command:
[
"-c",
"max_connections=2000",
"-c",
"effective_cache_size=25600MB",
"-c",
"work_mem=2MB",
"-c",
"wal_buffers=1MB",
"-c",
"synchronous_commit=off",
]
volumes:
- ~/.dockerdata/gotemplate/postgres:/var/lib/postgresql/data
ports:
- ${POSTGRES_PORT}:5432
env_file:
- .env
environment:
POSTGRES_USER: ${POSTGRES_USER}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
POSTGRES_DB: ${POSTGRES_NAME}
redis:
image: "redis:alpine"
command: redis-server --requirepass ${REDIS_PASSWORD}
ports:
- ${REDIS_PORT}:6379
volumes:
- ~/.dockerdata/gotemplate/redis-data:/var/lib/redis
- ~/.dockerdata/gotemplate/redis.conf:/usr/local/etc/redis/redis.conf
environment:
- REDIS_PASSWORD=${REDIS_PASSWORD}
- REDIS_PORT=${REDIS_PORT}