This repository has been archived by the owner on Apr 17, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 17
/
docker-compose-dev.yml
executable file
·141 lines (131 loc) · 3.45 KB
/
docker-compose-dev.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
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
version: '3.2'
services:
users-service:
container_name: users-service
build:
context: ./services/users
dockerfile: Dockerfile-dev
volumes:
- './services/users:/usr/src/app'
ports:
- 5001:5000
environment:
- SECRET_KEY=my_precious
- APP_SETTINGS=project.config.DevelopmentConfig
- DATABASE_URL=postgres://postgres:postgres@users-db:5432/users_dev
- DATABASE_TEST_URL=postgres://postgres:postgres@users-db:5432/users_test
depends_on:
- users-db
links:
- users-db
events-service:
container_name: events-service
build:
context: ./services/events
dockerfile: Dockerfile-dev
volumes:
- './services/events:/usr/src/app'
ports:
- 6000:6000
environment:
- SECRET_KEY=my_precious
- APP_SETTINGS=project.config.DevelopmentConfig
- DATABASE_URL=postgres://postgres:postgres@events-db:5432/events_dev
- DATABASE_TEST_URL=postgres://postgres:postgres@events-db:5432/events_test
- NEW_RELIC_ENVIRONMENT = 'development'
depends_on:
- events-db
links:
- events-db
events-task:
container_name: events-task
build:
context: ./services/events
dockerfile: Dockerfile-dev
volumes:
- './services/events:/usr/src/app'
environment:
- SECRET_KEY=my_precious
- APP_SETTINGS=project.config.DevelopmentConfig
- DATABASE_URL=postgres://postgres:postgres@events-db:5432/events_dev
- DATABASE_TEST_URL=postgres://postgres:postgres@events-db:5432/events_test
depends_on:
- events-db
links:
- events-db
events-db:
container_name: events-db
build:
context: ./services/events/project/db
dockerfile: Dockerfile
expose:
- 5432
environment:
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=postgres
users-db:
container_name: users-db
build:
context: ./services/users/project/db
dockerfile: Dockerfile
expose:
- 5432
environment:
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=postgres
nginx:
container_name: nginx
build: ./services/nginx
restart: always
ports:
- 80:80
depends_on:
- users-service
- client
- swagger
links:
- users-service
client:
container_name: client
build:
context: ./services/client
dockerfile: Dockerfile-dev
volumes:
- './services/client:/usr/src/app'
ports:
- '3007:3000' # expose ports - HOST:CONTAINER
environment:
- NODE_ENV=development
- CI=${CI:-false}
- REACT_APP_USERS_SERVICE_URL=${REACT_APP_USERS_SERVICE_URL}
- REACT_APP_EVENTS_SERVICE_URL=${REACT_APP_EVENTS_SERVICE_URL}
- REACT_APP_GOOGLE_ANALYTICS_ID=${REACT_APP_GOOGLE_ANALYTICS_ID:-UA-123052755-1}
depends_on:
- users-service
- events-service
links:
- users-service
- events-service
client-test:
container_name: client-test
build:
context: ./services/client
dockerfile: Dockerfile-dev
environment:
- NODE_ENV=development
- CI=${CI:-false}
volumes:
- './services/client:/usr/src/app'
swagger:
container_name: swagger
build:
context: ./services/swagger
dockerfile: Dockerfile-dev
volumes:
- './services/swagger/swagger.json:/usr/share/nginx/html/swagger.json'
ports:
- '3008:8080'
environment:
- URL=swagger.json
depends_on:
- users-service