-
Notifications
You must be signed in to change notification settings - Fork 5
/
docker-compose.yml_db_docker
executable file
·73 lines (67 loc) · 1.56 KB
/
docker-compose.yml_db_docker
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
version: '3'
services:
frontend:
build: "frontend"
image: "frontend"
container_name: "training-center-frontend"
ports:
- "${FRONTEND_PORT}:80"
depends_on:
- backend
backend:
build: "backend"
image: "backend"
restart: "always"
container_name: "training-center-backend"
environment:
- "NODE_ENV=${NODE_ENV}"
- "DATABASE_URL=${DATABASE_URL}"
- "SECRET_TOKEN=${SECRET_TOKEN}"
- "SMTP_HOST=${SMTP_HOST}"
- "SMTP_USER=${SMTP_USER}"
- "SMTP_PASSWORD=${SMTP_PASSWORD}"
- "FROM_ACCOUNT=${FROM_ACCOUNT}"
- "SMTP_SERVICE=${SMTP_SERVICE}"
- "SMTP_PORT=${SMTP_PORT}"
volumes:
- "${FILES}:/usr/src/app/files"
- "/var/run/docker.sock:/var/run/docker.sock"
ports:
- "${BACKEND_PORT}:8080"
depends_on:
- db
- cpp
- java
- python
db:
image: "mariadb:10.2"
restart: "always"
environment:
- "MYSQL_ROOT_PASSWORD=${MYSQL_PASSWORD}"
- "MYSQL_DATABASE=development"
container_name: "mariaDB"
ports:
- "${DATABASE_PORT}:3306"
cpp:
build: "grading/cpp"
image: "cpp_image"
container_name: "cppSandbox"
volumes:
- "${FILES}:/files"
tty: true
java:
build: "grading/java"
image: "java_image"
restart: "always"
container_name: "javaSandbox"
volumes:
- "${FILES}:/files"
tty: true
python:
build: "grading/python"
image: "python_image"
restart: "always"
container_name: "pythonSandbox"
volumes:
- "${FILES}:/files"
tty: true