-
Notifications
You must be signed in to change notification settings - Fork 8
/
Copy pathdocker-compose.yml
118 lines (112 loc) · 3.47 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
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
version: '3.8'
services:
db:
image: 'timescale/timescaledb:2.5.1-pg14'
restart: always
volumes:
- 'db_data:/var/lib/postgresql/data'
ports:
- "5432:5432"
environment:
PGDATA: /var/lib/postgresql/data/pgdata
POSTGRES_PASSWORD: postgres
POSTGRES_USER: postgres
POSTGRES_HOST_AUTH_METHOD: trust
web:
build:
context: .
dockerfile: ./Dockerfile
target: builder
depends_on:
- db
env_file:
- .env
ports:
- "${PROP_PROMETHEUS_METRICS_PORT:-9568}:${PROP_PROMETHEUS_METRICS_PORT:-9568}"
- "${WORKBENCH_PROMETHEUS_METRICS_PORT:-9569}:${WORKBENCH_PROMETHEUS_METRICS_PORT:-9569}"
- "${HISTORY_PROMETHEUS_METRICS_PORT:-9570}:${HISTORY_PROMETHEUS_METRICS_PORT:-9570}"
environment:
- DATABASE_URL=${DATABASE_URL:-ecto://postgres:postgres@db:5432/prop_?}
- RANCH_HTTP_PORT
- PROP_SECRET_KEY_BASE
- PROP_LIVE_VIEW_SIGNING_SALT
- WORKBENCH_SECRET_KEY_BASE
- WORKBENCH_LIVE_VIEW_SIGNING_SALT
- HISTORY_SECRET_KEY_BASE
- HISTORY_LIVE_VIEW_SIGNING_SALT
- RUBE_SECRET_KEY_BASE
- RUBE_LIVE_VIEW_SIGNING_SALT
- SLURPEE_SECRET_KEY_BASE
- SLURPEE_LIVE_VIEW_SIGNING_SALT
- LIVEBOOK_SECRET_KEY_BASE
- LIVEBOOK_LIVE_VIEW_SIGNING_SALT
- BALANCE_SNAPSHOT_ENABLED
- BALANCE_SNAPSHOT_BTC_USD_VENUE
- BALANCE_SNAPSHOT_BTC_USD_SYMBOL
- BALANCE_SNAPSHOT_USD_QUOTE_VENUE
- BALANCE_SNAPSHOT_USD_QUOTE_ASSET
volumes:
- web_build:/app/_build
- web_deps:/app/deps
- web_asset_node_modules:/app/assets/node_modules
- ./mix.exs:/app/mix.exs
- ./mix.lock:/app/mix.lock
- ./assets/css:/app/assets/css
- ./assets/js:/app/assets/js
- ./assets/static:/app/assets/static
- ./assets/package.json:/app/assets/package.json
- ./assets/package-lock.json:/app/assets/package-lock.json
- ./assets/webpack.config.js:/app/assets/webpack.config.js
- ./assets/tsconfig.json:/app/assets/tsconfig.json
- ./config:/app/config
- ./lib:/app/lib
- ./priv/repo:/app/priv/repo
entrypoint: "sh -c 'mix setup.deps && elixir --sname prop -S mix phx.server'"
prometheus:
image: 'prom/prometheus:v2.31.1'
restart: always
volumes:
- prometheus_data:/prometheus
- ./prometheus/:/etc/prometheus/
command:
- '--config.file=/etc/prometheus/prometheus.yml'
- '--storage.tsdb.path=/prometheus'
- '--web.console.libraries=/usr/share/prometheus/console_libraries'
- '--web.console.templates=/usr/share/prometheus/consoles'
grafana:
image: 'grafana/grafana:8.3.2'
restart: always
depends_on:
- db
volumes:
- grafana_data:/var/lib/grafana
- ./grafana/plugins:/var/lib/grafana/plugins
- ./grafana/grafana.ini:/etc/grafana/grafana.ini
- ./grafana/provisioning/:/etc/grafana/provisioning/
reverse_proxy:
build:
context: .
dockerfile: ./reverse_proxy/Dockerfile
ports:
- 80:80
volumes:
- ./reverse_proxy/templates:/etc/nginx/templates
- ./reverse_proxy/nginx.htpasswd:/etc/nginx/conf.d/nginx.htpasswd
environment:
- RANCH_HTTP_PORT
- REVERSE_PROXY_HTTP_PORT
- PROP_HOST
- WORKBENCH_HOST
- HISTORY_HOST
- RUBE_HOST
- SLURPEE_HOST
- LIVEBOOK_HOST
- GRAFANA_HOST
- PROMETHEUS_HOST
volumes:
db_data:
web_build:
web_deps:
web_asset_node_modules:
prometheus_data:
grafana_data: