-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.prod.yml
53 lines (49 loc) · 1.3 KB
/
docker-compose.prod.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
version: '3'
services:
mongo:
container_name: mongo
image: mongo
restart: always
command: --smallfiles --bind_ip_all
environment:
ME_CONFIG_MONGODB_ADMINUSERNAME: ${MONGODB_ADMINUSERNAME}
ME_CONFIG_MONGODB_ADMINPASSWORD: ${MONGODB_ADMINPASSWORD}
MONGO_INITDB_DATABASE: backoffice
volumes:
- ./mongo/db:/data/db:delegated
- ./mongo/init.js:/docker-entrypoint-initdb.d/init.js
expose:
- ${MONGODB_PORT}
client:
container_name: client
build:
context: ./client
dockerfile: Dockerfile.prod
expose:
- ${CLIENT_APP_PORT}
links:
- server
server:
container_name: server
restart: always
build:
context: ./server
dockerfile: Dockerfile.prod
expose:
- ${SERVER_APP_PORT}
links:
- mongo
env_file: .env
proxy:
container_name: proxy
image: abiosoft/caddy
ports:
- '80:80'
- '443:443'
- '8080:8080'
links:
- client
- server
volumes:
- './Caddyfile.prod:/etc/Caddyfile'
- './.caddy:/root/.caddy'