-
Notifications
You must be signed in to change notification settings - Fork 11
/
docker-compose.yml
executable file
·95 lines (94 loc) · 3.11 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
services:
webapp:
build:
context: ./back
args:
env: ${ENVIRONMENT:-development}
ports:
- 5005:5005
# request localhost:5001 to run debugger in vscode (cf. README)
- 5001:5001
networks:
- backend
volumes:
- ./back:/app/back
environment:
PYTHONUNBUFFERED: 1
AUTH0_DOMAIN: ${AUTH0_DOMAIN:?auth0 config not set in .env file}
AUTH0_AUDIENCE: ${AUTH0_AUDIENCE:?auth0 config not set in .env file}
AUTH0_CLIENT_ID: ${TEST_AUTH0_CLIENT_ID}
AUTH0_CLIENT_SECRET: ${TEST_AUTH0_CLIENT_SECRET}
TEST_AUTH0_CLIENT_ID: ${TEST_AUTH0_CLIENT_ID}
TEST_AUTH0_CLIENT_SECRET: ${TEST_AUTH0_CLIENT_SECRET}
AUTH0_PUBLIC_KEY: ${AUTH0_PUBLIC_KEY:-}
MYSQL_HOST: ${MYSQL_HOST:-db}
MYSQL_USER: ${MYSQL_USER:-root}
MYSQL_PASSWORD: ${MYSQL_PASSWORD:-dropapp_root}
MYSQL_DB: ${MYSQL_DB:-dropapp_dev}
MYSQL_PORT: ${MYSQL_PORT:-3306}
ENVIRONMENT: ${ENVIRONMENT:-development}
CI: "true"
depends_on:
- db
front:
build:
context: .
dockerfile: ./Dockerfile
args:
SERVICE_DIR: front
environment:
NODE_ENV: development
HUSKY: 0
FRONT_ENVIRONMENT: ${ENVIRONMENT:-development}
FRONT_SENTRY_ENVIRONMENT: ${ENVIRONMENT:-development}
FRONT_SENTRY_FE_DSN: ${SENTRY_FE_DSN:-}
FRONT_SENTRY_TRACES_SAMPLE_RATE: ${SENTRY_TRACES_SAMPLE_RATE:-}
FRONT_AUTH0_DOMAIN: ${AUTH0_DOMAIN:?auth0 config not set in .env file}
FRONT_AUTH0_CLIENT_ID: ${AUTH0_CLIENT_ID:?auth0 config not set in .env file}
FRONT_AUTH0_AUDIENCE: ${AUTH0_AUDIENCE:?auth0 config not set in .env file}
FRONT_REDIRECT: http://localhost:3000
FRONT_LOGOUT_URL: http://localhost:3000
FRONT_GRAPHQL_SERVER: http://localhost:5005/graphql
FRONT_OLD_APP_BASE_URL: ${OLD_APP_BASE_URL:-http://localhost:8100}
ports:
- "3000:3000"
stdin_open: true
volumes:
- .:/app
# this is a workaround to prevent host node_modules from accidently getting mounted in container
# in case you want to use node/npm both outside container for test/lint etc.
- /app/node_modules
- /app/front/node_modules
statviz:
build:
context: .
dockerfile: ./Dockerfile
args:
SERVICE_DIR: statviz
environment:
NODE_ENV: development
STATVIZ_GRAPHQL_SERVER: http://localhost:5005/public
ports:
- "5173:5173"
stdin_open: true
volumes:
- .:/app
- /app/node_modules
- /app/statviz/node_modules
db:
image: mysql/mysql-server:8.0 # We run MySQL 8.0 on the production environment atm
command: --default-authentication-plugin=mysql_native_password --lower_case_table_names=1 --character-set-server=utf8mb4 --collation-server=utf8mb4_0900_ai_ci
environment:
MYSQL_ROOT_PASSWORD: dropapp_root
MYSQL_ROOT_HOST: "%"
MYSQL_DATABASE: dropapp_dev
volumes:
- ./back/init.sql:/docker-entrypoint-initdb.d/init.sql
ports:
# <Port exposed> : < MySQL Port running inside container>
- 32000:3306
networks:
- backend
networks:
backend:
driver: bridge