forked from Chrischuck/websocket-docker-example
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
37 lines (34 loc) · 736 Bytes
/
docker-compose.yml
File metadata and controls
37 lines (34 loc) · 736 Bytes
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
version: '3.3'
volumes:
postgres-data:
services:
chat-client:
build:
context: ./client
dockerfile: Dockerfile
image: chat/client
command: node server.js
ports:
- '5008:8080'
chat-api:
build:
context: ./api
dockerfile: Dockerfile
image: chat/api
command: bash -c "forever --watch src/index.js"
environment:
- POSTGRES_CONNECTION_URI=postgres://postgres:password@postgres:5432/chat
ports:
- '5006:3000'
postgres:
image: postgres
restart: always
volumes:
- postgres-data:/var/lib/postgresql/data
environment:
POSTGRES_PASSWORD: password
POSTGRES_DB: chat
ports:
- '5005:5432'
expose:
- '5432'