-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
54 lines (52 loc) · 1.21 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
version: '3'
services:
server:
container_name: backend
build: ./server
expose:
- ${SERVER_PORT}
environment:
- API_HOST=${API_HOST}
- SERVER_PORT=${SERVER_PORT}
- API_KEY=${API_KEY}
- PROJECT_ID=${PROJECT_ID}
- APP_ID=${APP_ID}
- APP_SECRET=${APP_SECRET}
- POSTGRES_PORT=5432
- POSTGRES_HOST=postgres
- POSTGRES_DB=${POSTGRES_DB}
- POSTGRES_USER=${POSTGRES_USER}
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD}
ports:
- ${SERVER_PORT}:${SERVER_PORT}
volumes:
- ./server/app:/www/app/bwitter/server/app
command: npm start
restart: always
depends_on:
- postgres
client:
build: ./client
expose: ${CLIENT_PORT}
environment:
- CLIENT_PORT=${CLIENT_PORT}
expose:
- ${CLIENT_PORT}
ports:
- ${CLIENT_PORT}:${CLIENT_PORT}
volumes:
- ./client/src:/www/app/bwitter/client/src
links:
- server
depends_on:
- "server"
command: npm start
postgres:
image: postgres:13
restart: always
environment:
- POSTGRES_DB=${POSTGRES_DB}
- POSTGRES_USER=${POSTGRES_USER}
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD}
ports:
- 5432:5432