forked from guilhermejansen/wuzapi
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose-swarm.yaml
More file actions
56 lines (53 loc) · 1.48 KB
/
docker-compose-swarm.yaml
File metadata and controls
56 lines (53 loc) · 1.48 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
version: '3.8'
services:
wuzapi-server:
image: setupautomatizado/wuzapi-server:latest
networks:
- network_public
environment:
- WUZAPI_ADMIN_TOKEN=H4Zbhw72PBKdTIgS
- PORT=8080
- DB_DIALECT=sqlite
- DATABASE_URL=/app/dbdata/users.db
volumes:
- wuzapi_dbdata:/app/dbdata
- wuzapi_files:/app/files
deploy:
mode: replicated
replicas: 1
update_config:
parallelism: 1
order: rolling-update
restart_policy:
condition: on-failure
placement:
constraints: [node.role == manager]
resources:
limits:
cpus: "1"
memory: 512MB
labels:
- traefik.enable=true
- traefik.http.routers.wuzapi-server.rule=Host(`api.wuzapi.app`)
- traefik.http.routers.wuzapi-server.entrypoints=websecure
- traefik.http.routers.wuzapi-server.priority=1
- traefik.http.routers.wuzapi-server.tls.certresolver=letsencryptresolver
- traefik.http.routers.wuzapi-server.service=wuzapi-server
- traefik.http.services.wuzapi-server.loadbalancer.server.port=5000
# healthcheck:
# test: ["CMD", "curl", "-f", "http://localhost:8080/health"]
# interval: 10s
# timeout: 5s
# retries: 3
# start_period: 10s
networks:
network_public:
name: network_public
external: true
volumes:
wuzapi_dbdata:
external: true
name: wuzapi_dbdata
wuzapi_files:
external: true
name: wuzapi_files