forked from 18F/culper
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
100 lines (93 loc) · 2.04 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
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
version: '2'
services:
db:
image: postgres:9.6.5
volumes:
- ./conf/postgres-configure.sh:/docker-entrypoint-initdb.d/postgres-configure.sh
- ./conf/postgres.conf:/srv/postgresql.conf
- ./api/eapp.crt:/srv/server.crt
- ./api/eapp.key:/srv/server.key
expose:
- '5432'
networks:
- eapp
# Within the docker world this is the main entrypoint in to
# this web application. This was done in order to have a
# combination of:
# - development REPL
# - automated unit tests
# - spec testing
#
# The web server will do the following:
# - serve compiled static assets
# - proxy /api requests to the backend API
web:
image: nginx:alpine
command: nginx
volumes:
- ./conf/ssl:/etc/ssl
- ./conf/nginx.conf:/etc/nginx/nginx.conf
- ./dist:/usr/share/nginx/html
ports:
- '8080:8080'
- '8443:8443'
networks:
- eapp
depends_on:
- api
frontend:
image: node:8.5.0
env_file:
- .env
working_dir: /usr/src/app
volumes:
- .:/usr/src/app
# - /usr/src/app/node_modules
command: ./bin/watch
networks:
- eapp
api:
build:
context: .
dockerfile: Dockerfile.api
env_file:
- .env
working_dir: /go/src/github.com/18F/e-QIP-prototype/api
command: ./bin/run.sh
volumes:
- .:/go/src/github.com/18F/e-QIP-prototype
expose:
- '3000'
environment:
DATABASE_USER: postgres
DATABASE_NAME: postgres
DATABASE_HOST: db:5432
networks:
- eapp
depends_on:
- db
docs:
build:
context: .
dockerfile: Dockerfile.docs
volumes:
- .:/usr/src/app
- /usr/src/app/node_modules
working_dir: /usr/src/app
command: ./bin/docs.sh
networks:
- eapp
depends_on:
- db
deps:
image: buildpack-deps:stretch-scm
volumes:
- .:/usr/src/app
working_dir: /usr/src/app
environment:
DEBIAN_FRONTEND: noninteractive
networks:
- eapp
networks:
eapp:
driver: bridge