-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
35 lines (31 loc) · 997 Bytes
/
Copy pathdocker-compose.yml
File metadata and controls
35 lines (31 loc) · 997 Bytes
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
# docker-compose.yml (로컬 개발용)
# RDS/ELastiCache는 Docker로 띄우지 않습니다
services:
postgres:
image: postgres:16
container_name: deliverycommerce-postgres
restart: no # prod환경에선 always
environment:
POSTGRES_DB: deliverycommerce
POSTGRES_USER: babjo
POSTGRES_PASSWORD: babjo1234
POSTGRES_INITDB_ARGS: "--locale=C --encoding=UTF8" #인코딩 설정 (가나다순 정렬 지원)
# 기존 도커 올리신 분들은
# docker compose down
# docker volume rm com.babjo.deliverycommerce_postgres-data
# docker compose up -d
# 순서대로 해서 기존 데이터 지우고 새로 작성
ports:
- "5432:5432"
volumes:
- postgres-data:/var/lib/postgresql/data # 컨테이너 내려도 데이터 유지
redis:
image: redis:7
container_name: deliverycommerce-redis
ports:
- "6379:6379"
volumes:
- redis-data:/data
volumes:
postgres-data:
redis-data: