-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
52 lines (48 loc) · 1.07 KB
/
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
44
45
46
47
48
49
50
51
52
version: "3"
services:
web:
build:
context: ./frontend
dockerfile: Dockerfile
volumes:
- ./frontend/:/frontend/
- node_modules:/frontend/node_modules
ports:
- 5173:5173
environment:
- NODE_ENV=development
restart: always
tty: true
depends_on:
- server
command: yarn run dev
server:
build:
context: ./backend
dockerfile: Dockerfile
volumes:
- ./backend/:/backend/
ports:
- 8000:8000
restart: always
tty: true
depends_on:
- db
command: uvicorn app.main:app --reload --host 0.0.0.0 --port 8000
db:
image: postgres:15
container_name: postgres-db
volumes:
- db-store:/var/lib/postgresql/data
- ./backend/db/init:/docker-entrypoint-initdb.d
environment:
ENV LANG: ja_JP.UTF-8 # postgres内の文字コードを指定
TZ: Asia/Tokyo # postgres内のTimeZoneを指定
POSTGRES_DB: postgres
POSTGRES_USER: postgres
POSTGRES_PASSWORD: password
ports:
- 5432:5432
volumes:
db-store:
node_modules: