-
Notifications
You must be signed in to change notification settings - Fork 1
/
docker-compose.yml
53 lines (50 loc) · 1.35 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
version: "3"
services:
app:
build:
context: .
dockerfile: Dockerfile
container_name: k-cse-server
environment:
- SPRING_PORT=${SPRING_PORT}
- DB_HOST=${DB_HOST}
- DB_PORT=${DB_PORT}
- DB_DATABASE=${DB_DATABASE}
- DB_USERNAME=${DB_USERNAME}
- DB_PASSWORD=${DB_PASSWORD}
- DB_ROOT_PASSWORD=${DB_ROOT_PASSWORD}
- JWT_SECRET=${JWT_SECRET}
- GOOGLE_CLIENT_ID=${GOOGLE_CLIENT_ID}
- GOOGLE_CLIENT_SECRET=${GOOGLE_CLIENT_SECRET}
- GOOGLE_REDIRECT_URI=${GOOGLE_REDIRECT_URI}
- CORS_ALLOWED_ORIGINS=${CORS_ALLOWED_ORIGINS}
- OAUTH2_REDIRECT_URI=${OAUTH2_REDIRECT_URI}
depends_on:
- database
ports:
- ${SPRING_PORT}:${SPRING_PORT}
restart: always
database:
image: mysql:8.0
container_name: k-cse-database
environment:
TZ: Asia/Seoul
LANG: C.UTF-8
MYSQL_DATABASE: ${DB_DATABASE}
MYSQL_USER: ${DB_USERNAME}
MYSQL_PASSWORD: ${DB_PASSWORD}
MYSQL_ROOT_PASSWORD: ${DB_ROOT_PASSWORD}
command:
- --port=${DB_PORT}
- --character-set-server=utf8mb4
- --collation-server=utf8mb4_unicode_ci
- --skip-character-set-client-handshake
expose:
- ${DB_PORT}
ports:
- ${DB_PORT}:${DB_PORT}
restart: always
volumes:
- k-cse-database:/var/lib/mysql
volumes:
k-cse-database: