This repository has been archived by the owner on Sep 17, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.prod.yml
69 lines (69 loc) · 2.07 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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
# Sets up multiple services to demonstrate how a server cluster would run with cloud storage, authorization, caching and monitoring
# This file requires the existense of .env with neccessary variable
# The docker-compose file is added for emulation of how the application can be setup with full functionality
version: "3"
services:
mongodb:
image: mongo
ports:
- 27017:27017
environment:
- MONGO_INITDB_ROOT_USERNAME=${DB_USERNAME}
- MONGO_INITDB_ROOT_PASSWORD=${DB_PASSWORD}
volumes:
- mongo-data:/data/db
redis:
image: redis
ports:
- 6379:6379
volumes:
- ./redis.conf:/usr/local/etc/redis/redis.conf
command: redis-server /usr/local/etc/redis/redis.conf
arserver:
image: alanjohn/argorithm-server:latest
ports:
- 80:80
environment:
- DATABASE=MONGO
- AUTH=ENABLED
- SECRET_KEY=${SECRET_KEY}
- DB_USERNAME=${DB_USERNAME}
- DB_PASSWORD=${DB_PASSWORD}
- DB_ENDPOINT=mongodb
- DB_PORT=27017
- ADMIN_EMAIL=${ADMIN_EMAIL}
- ADMIN_PASSWORD=${ADMIN_PASSWORD}
- CACHING=ENABLED
- REDIS_HOST=redis
- REDIS_PORT=6379
- REDIS_PASSWORD=notmypassword
volumes:
- uploads:/tmp/argorithm
depends_on:
- mongodb
- redis
prometheus:
image: prom/prometheus
ports:
- 9090:9090
command:
- --config.file=/etc/prometheus/prometheus.yml
volumes:
- ./prometheus.yml:/etc/prometheus/prometheus.yml:ro
depends_on:
- arserver
grafana:
image: grafana/grafana
ports:
- 3000:3000
volumes:
- ./grafana/datasource.yml:/etc/grafana/provisioning/datasource.yml
env_file:
- ./grafana/config.monitoring
depends_on:
- prometheus
volumes:
mongo-data:
driver: local
uploads:
driver: local