-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocker-compose.yml
70 lines (65 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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
version: "3"
services:
db:
container_name: db
image: mysql:latest
volumes:
- /var/lib/mysql
restart: always
networks:
- webnet
environment:
MYSQL_ROOT_PASSWORD: masterpassword
MYSQL_DATABASE: database
MYSQL_USER: root
ports:
- 3306:3306
client:
container_name: client
image: marcelorl/e-commerce-client:latest
command: "yarn start"
depends_on:
- server
networks:
- webnet
# build: ./client
volumes:
- ./client:/project
ports:
- 3000:3000
environment:
SERVER: http://localhost:1337
server:
container_name: server
image: marcelorl/e-commerce-server:latest
depends_on:
- db
# build: ./server
networks:
- webnet
volumes:
- ./server:/project
links:
- db
ports:
- 1337:1337
environment:
PORT: 1337
DB_DATABASE: database
DB_USER: root
DB_PASSWORD: masterpassword
DB_HOST: db
DB_PORT: 3306
# nginx:
# image: nginx
# volumes:
# - ./nginx/config.template:/etc/nginx/conf.d/config.template
# ports:
# - "1337:80"
# networks:
# - webnet
# depends_on:
# - server
# command: /bin/bash -c "envsubst < /etc/nginx/conf.d/config.template > /etc/nginx/conf.d/default.conf && nginx -g 'daemon off;'"
networks:
webnet: