-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yaml
69 lines (66 loc) · 1.24 KB
/
docker-compose.yaml
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
version: '3'
services:
db:
image: postgres:latest
environment:
POSTGRES_PASSWORD: password
POSTGRES_USER: root
POSTGRES_INIIT_ARGS: "--encoding=UTF-8"
cap_add:
- SYS_NICE
networks:
- sink
user: root
proxy:
build:
context: .
dockerfile: Dockerfile.proxy
command: caddy run --config /etc/caddy/Caddyfile --adapter caddyfile
ports:
- "80:80"
- "443:443"
networks:
- membrane
- pool
api:
build:
context: .
dockerfile: Dockerfile.api
command: bundle exec rails s -p 3000 -b '0.0.0.0'
environment:
RAILS_ENV: production
RAKE_ENV: production
volumes:
- .:/app
- /images
- /var/run/docker.sock:/var/run/docker.sock
ports:
- "3000:3000"
networks:
- membrane
- sink
depends_on:
- db
- proxy
networks:
membrane:
name: membrane
driver: bridge
ipam:
driver: default
config:
- subnet: 172.30.1.0/24
sink:
name: sink
driver: bridge
ipam:
driver: default
config:
- subnet: 172.30.2.0/24
pool:
name: pool
driver: bridge
ipam:
driver: default
config:
- subnet: 10.0.0.0/8