This repository has been archived by the owner on Dec 3, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
115 lines (109 loc) · 2.81 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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
version: '2'
services:
redis:
image: redis:3.2
restart: unless-stopped
ports:
- 6379:6379
volumes:
- redis:/data
postgres:
image: postgres:10
restart: unless-stopped
environment:
POSTGRES_DB: pstate
POSTGRES_PASSWORD: pstate
POSTGRES_USER: pstate
ports:
- 5432:5432
volumes:
- postgres:/var/lib/postgresql/data
# pstate web ui
webui:
build:
context: ./
dockerfile: docker_build/pstate_webui/Dockerfile
restart: unless-stopped
environment:
DJANGO_SETTINGS_MODULE: ictsc_prep_school.settings.pstate.local
POSTGRES_DB: pstate
POSTGRES_USER: pstate
POSTGRES_PASSWORD: pstate
POSTGRES_HOST: postgres
POSTGRES_PORT: 5432
REDIS_HOST: redis
REDIS_PORT: 6379
MODE: web
SCORE_SERVER_API_URL: http://localhost:8900
SCORE_SERVER_AUTH_USER_NAME: staff
SCORE_SERVER_AUTH_PASSWORD: staff
depends_on:
- postgres
- redis
ports:
- 8088:80
# terraformコマンドが実行するservice.
worker:
build:
context: ./
dockerfile: docker_build/terraform_manager_worker/Dockerfile
restart: unless-stopped
environment:
DJANGO_SETTINGS_MODULE: ictsc_prep_school.settings.terraform_manager.local
POSTGRES_DB: pstate
POSTGRES_USER: pstate
POSTGRES_PASSWORD: pstate
POSTGRES_HOST: postgres
POSTGRES_PORT: 5432
REDIS_HOST: redis
REDIS_PORT: 6379
SCORE_SERVER_API_URL: http://localhost:8900
SCORE_SERVER_AUTH_USER_NAME: staff
SCORE_SERVER_AUTH_PASSWORD: staff
depends_on:
- postgres
- redis
# スコアサーバへ通知を行うservice.
#notify-worker:
# build:
# context: ./
# dockerfile: docker_build/pstate_webui/Dockerfile
# restart: unless-stopped
# environment:
# DJANGO_SETTINGS_MODULE: ictsc_prep_school.settings.pstate.local
# POSTGRES_DB: pstate
# POSTGRES_USER: pstate
# POSTGRES_PASSWORD: pstate
# POSTGRES_HOST: postgres
# POSTGRES_PORT: 5432
# REDIS_HOST: redis
# REDIS_PORT: 6379
# MODE: notify
# SCORE_SERVER_API_URL: http://localhost:8900
# SCORE_SERVER_AUTH_USER_NAME: staff
# SCORE_SERVER_AUTH_PASSWORD: staff
# depends_on:
# - postgres
# - redis
# DBの初期化を行うservice.
init:
build:
context: ./
dockerfile: docker_build/pstate_webui/Dockerfile
environment:
DJANGO_SETTINGS_MODULE: ictsc_prep_school.settings.pstate.local
POSTGRES_DB: pstate
POSTGRES_USER: pstate
POSTGRES_PASSWORD: pstate
POSTGRES_HOST: postgres
POSTGRES_PORT: 5432
REDIS_HOST: redis
REDIS_PORT: 6379
MODE: init
depends_on:
- postgres
volumes:
postgres:
external: false
redis:
external: false