-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
129 lines (118 loc) · 3.91 KB
/
docker-compose.yml
File metadata and controls
129 lines (118 loc) · 3.91 KB
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
119
120
121
122
123
124
125
126
127
128
129
services:
# ----------------------------------------
# --- Application
# ----------------------------------------
manon:
container_name: manon
image: lermitage-manon:1.0.0-SNAPSHOT
ports:
- "8081:8080"
volumes:
- ~/manon-app-logs:/logs
environment:
MANON_SQL_USERNAME: root
MANON_SQL_PASSWORD: woot
MANON_SQL_JDBC_URL: jdbc:mariadb://maria:3306/manon?useUnicode=true&characterEncoding=utf8&autoReconnect=true
MANON_BATCH_SQL_USERNAME: root
MANON_BATCH_SQL_PASSWORD: woot
MANON_BATCH_SQL_JDBC_URL: jdbc:mariadb://maria-batch:3306/manon_batch?useUnicode=true&characterEncoding=utf8&autoReconnect=true
MANON_REDIS_DATABASE: 1
MANON_REDIS_HOST: redis
MANON_REDIS_PORT: 6379
MANON_REDIS_MANAGEMENT: "true"
MANON_MAIL_HOST: "greenmail"
MANON_MAIL_PORT: 3025
MANON_MAIL_USERNAME: "sender"
MANON_MAIL_PASSWORD: "woot"
MANON_MAIL_TEST_CONNECTION: "true"
depends_on:
- maria
- redis
- greenmail
healthcheck:
test: ["CMD-SHELL", "curl -f http://127.0.0.1:8080/actuator/health || exit 1"]
interval: 30s
timeout: 10s
retries: 3
start_period: 40s
maria:
container_name: maria
image: mariadb:11.5.2 # see https://hub.docker.com/_/mariadb/
ports:
- "3306:3306"
volumes:
- ~/manon-maria-db:/var/lib/mysql
environment:
MYSQL_ROOT_PASSWORD: woot
MYSQL_DATABASE: manon
healthcheck:
test: ["CMD-SHELL", "timeout 1 bash -c 'cat < /dev/null > /dev/tcp/127.0.0.1/3306' || exit 1"]
interval: 30s
timeout: 10s
retries: 3
start_period: 40s
maria-batch:
container_name: maria-batch
image: mariadb:11.5.2 # see https://hub.docker.com/_/mariadb/
ports:
- "3308:3306"
volumes:
- ~/manon-maria-db-batch:/var/lib/mysql
environment:
MYSQL_ROOT_PASSWORD: woot
MYSQL_DATABASE: manon_batch
healthcheck:
test: ["CMD-SHELL", "timeout 1 bash -c 'cat < /dev/null > /dev/tcp/127.0.0.1/3306' || exit 1"]
interval: 30s
timeout: 10s
retries: 3
start_period: 40s
redis:
container_name: redis
image: redis:7.4.1-alpine # see https://hub.docker.com/_/redis/
ports:
- "6379:6379"
volumes:
- ./redis/redis.conf:/usr/local/etc/redis/redis.conf
command: redis-server /usr/local/etc/redis/redis.conf
greenmail:
container_name: greenmail
image: greenmail/standalone:1.6.15 # see https://hub.docker.com/r/greenmail/standalone
ports:
- "3025:3025"
environment:
# see config http://www.icegreen.com/greenmail/index.html#deploy_docker_standalone
GREENMAIL_OPTS: "-Dgreenmail.setup.test.smtp -Dgreenmail.hostname=0.0.0.0 -Dgreenmail.users=sender:woot"
JAVA_OPTS: "-Djava.net.preferIPv4Stack=true -Xms32m -Xmx512m"
# ----------------------------------------
# --- Frontend proxy
# ----------------------------------------
nginx:
container_name: nginx
image: nginx:1.23.2-alpine # see https://hub.docker.com/_/nginx/
ports:
- "8000:80"
volumes:
- ~/manon-nginx-logs:/var/log/nginx
- ./nginx/nginx.conf:/etc/nginx/nginx.conf
depends_on:
- manon # to proxy app
# ----------------------------------------
# --- Metrics collection
# ----------------------------------------
prometheus:
container_name: prometheus
image: prom/prometheus:v2.40.2 # see https://hub.docker.com/r/prom/prometheus
ports:
- "9090:9090"
volumes:
- ./prometheus/prometheus.yml:/etc/prometheus/prometheus.yml
grafana:
container_name: grafana
image: grafana/grafana:9.2.6 # see https://hub.docker.com/r/grafana/grafana
ports:
- "3000:3000"
volumes:
# see default paths https://grafana.com/docs/grafana/latest/installation/docker/#default-paths
- ~/manon-grafana-data:/var/lib/grafana
- ./grafana/grafana.ini:/etc/grafana/grafana.ini