-
Notifications
You must be signed in to change notification settings - Fork 1
/
docker-compose-local.yaml
70 lines (62 loc) · 1.66 KB
/
docker-compose-local.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
version: '3'
services:
consul:
image: hashicorp/consul:1.16.0
command: agent -server -ui -node=server-1 -bootstrap-expect=1 -client=0.0.0.0
ports:
- "8500:8500" # Consul UI and API
- "8600:8600/udp" # Consul DNS
restart: always
traefik:
restart: always
# The official v3 Traefik docker image
image: traefik:v3.1
# Enables the web UI and tells Traefik to listen to docker
command:
- "--configFile=/etc/traefik/traefik.yaml"
ports:
# The HTTP port
- "80:80"
# The Web UI (enabled by --api.insecure=true)
- "8080:8080"
volumes:
# So that Traefik can listen to the Docker events
- /var/run/docker.sock:/var/run/docker.sock
- ./traefik/traefik.yaml:/etc/traefik/traefik.yaml
- ./traefik/dynamic_conf.toml:/etc/traefik/dynamic_conf.toml
postgres:
image: postgres:16.2-bookworm
restart: always
environment:
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=postgres
ports:
- "5432:5432"
volumes:
- pg-data:/var/lib/postgresql/data
- ./init.sql:/docker-entrypoint-initdb.d/init.sql
redis:
image: redis:6.2-alpine
command: redis-server
restart: always
ports:
- "6379:6379"
volumes:
- redis-data:/data
rabbitmq:
image: rabbitmq:3.10.7-management
restart: always
ports:
- "5672:5672" # RabbitMQ default port
- "15672:15672" # RabbitMQ Management Plugin
environment:
- RABBITMQ_DEFAULT_USER=guest
- RABBITMQ_DEFAULT_PASS=guest
volumes:
- rabbitmq-data:/var/lib/rabbitmq
volumes:
pg-data:
redis-data:
driver: local
rabbitmq-data:
driver: local