forked from jadilson12/docker-compose-stack
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.example
47 lines (42 loc) · 973 Bytes
/
docker-compose.example
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
version: '3'
services:
database-service:
image: kartoza/postgis
container_name: app-database
environment:
- POSTGRES_DB=adonis_db
- POSTGRES_DB_TEST=adonis_db_teste
- POSTGRES_USER=adonis_usr
- POSTGRES_PASSWORD=123456
ports:
- "5432:5432"
expose:
- "5432"
volumes:
- ./database/docker-data/postgres:/var/lib/postgresql/data
# - ./database/schema.sql:/docker-entrypoint-initdb.d/0.schema.sql
api-service:
image: jadilson12/node-api
container_name: app-api
user: "node"
volumes:
- ./api:/api
command:
sh -c 'npm start'
ports:
- "3333:3333"
environment:
- DB_HOST=app-database
- DB_PORT=5432
depends_on:
- database-service
webapp-service:
image: jadilson12/node-app-web
container_name: app-webapp
user: "node"
volumes:
- ./web-app:/app
command:
sh -c 'npm start'
ports:
- "8080:8080"