forked from Zie619/n8n-workflows
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.prod.yml
More file actions
66 lines (63 loc) · 2.06 KB
/
docker-compose.prod.yml
File metadata and controls
66 lines (63 loc) · 2.06 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
services:
workflows-docs:
restart: always
environment:
- ENVIRONMENT=production
- LOG_LEVEL=warning
- ENABLE_METRICS=true
- MAX_WORKERS=4
volumes:
- workflows-db:/app/database
- workflows-logs:/app/logs
- ./workflows:/app/workflows:ro # Read-only workflow files
deploy:
resources:
limits:
memory: 512M
cpus: '0.5'
reservations:
memory: 256M
cpus: '0.25'
labels:
- "traefik.enable=true"
- "traefik.http.routers.workflows-docs.rule=Host(`workflows.yourdomain.com`)"
- "traefik.http.routers.workflows-docs.tls=true"
- "traefik.http.routers.workflows-docs.tls.certresolver=myresolver"
- "traefik.http.services.workflows-docs.loadbalancer.server.port=8000"
- "traefik.http.middlewares.workflows-docs-auth.basicauth.users=admin:$$2y$$10$$..." # Generate with htpasswd
# Production reverse proxy
reverse-proxy:
restart: always
- "traefik.http.middlewares.workflows-docs-auth.basicauth.users=admin:$$2y$$12$$eImiTXuWVxfM37uY4JANjQ=="
# Example hash for password 'examplepassword'. Generate your own with: htpasswd -nbB <user> <password>
# See: https://doc.traefik.io/traefik/middlewares/http/basicauth/
volumes:
- ./traefik/config:/etc/traefik/dynamic:ro
- ./ssl:/ssl:ro
environment:
- TRAEFIK_LOG_LEVEL=INFO
deploy:
resources:
limits:
memory: 256M
cpus: '0.25'
# Optional: Monitoring stack
monitoring:
image: prom/prometheus:latest
container_name: prometheus
command:
- '--config.file=/etc/prometheus/prometheus.yml'
- '--storage.tsdb.path=/prometheus'
- '--web.console.libraries=/etc/prometheus/console_libraries'
- '--web.console.templates=/etc/prometheus/consoles'
ports:
- "9090:9090"
volumes:
- ./monitoring/prometheus.yml:/etc/prometheus/prometheus.yml:ro
- prometheus-data:/prometheus
networks:
- workflows-network
profiles:
- monitoring
volumes:
prometheus-data: