-
Notifications
You must be signed in to change notification settings - Fork 1
/
compose.yaml
76 lines (74 loc) · 1.64 KB
/
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
70
71
72
73
74
75
76
version: "3.8"
services:
web:
build: .
volumes:
- .:/var/lib/app/
ports:
- "80:80/tcp"
- "443:443/tcp"
- "80:80/udp"
- "443:443/udp"
expose:
- "80:80/tcp"
- "443:443/tcp"
- "80:80/udp"
- "443:443/udp"
environment:
- POSTGRES_URI=postgres://user:password@postgres:5432/app
- MONGODB_URI=mongodb://mongodb:27017/app
depends_on:
- mongodb
- postgres
networks:
- default
postgres:
image: postgres:17beta1
environment:
- POSTGRES_USER=user
- POSTGRES_PASSWORD=password
- POSTGRES_DB=app
restart: unless-stopped
volumes:
- type: volume
source: data
target: /var/lib/postgresql/data/
- type: volume
source: ./src/sql/init.sql
target: /docker-entrypoint-initdb.d/0-init.sql
ports:
- "5432:5432/tcp"
mongodb:
image: mongo:8.0.0
restart: unless-stopped
ports:
- "27017:27017/tcp"
volumes:
- type: volume
source: data
target: /var/lib/mongodb
networks:
- default
elastic:
image: docker.elastic.co/elasticsearch/elasticsearch:8.15.1
environment:
- node.name=elasticsearch
- cluster.name=elasticsearch
- discovery.seed_hosts=elasticsearch
- cluster.initial_master_nodes=elasticsearch
- bootstrap.memory_lock=true
- "ES_JAVA_OPTS=-Xms512m -Xmx512m"
ulimits:
memlock:
soft: -1
hard: -1
volumes:
- type: volume
source: data
target: /usr/share/elasticsearch/data
ports:
- "9200:9200/tcp"
volumes:
data:
networks:
default: