forked from mhzawadi/invoiceplane
-
Notifications
You must be signed in to change notification settings - Fork 0
/
stack-invoiceplane.yml
61 lines (58 loc) · 1.69 KB
/
stack-invoiceplane.yml
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
version: '3.5'
# docker stack deploy --compose-file stack-invoiceplane.yml invoiceplane
volumes:
invoiceplane_data:
mariadb_10_4:
services:
proxyv2:
image: traefik:v2.0 # The official Traefik docker image
command:
- "--api.insecure=true"
- "--providers.docker"
- "--providers.docker.swarmMode=true"
ports:
- "80:80" # The HTTP port
- "443:443" # The HTTP port
- "8181:8080" # The Web UI (enabled by --api)
volumes:
- /var/run/docker.sock:/var/run/docker.sock # So that Traefik can listen to the Docker events
deploy:
mode: replicated
replicas: 1
labels:
- "traefik.enable=false"
invoiceplane:
image: mhzawadi/invoiceplane:v1.5.9.2
volumes:
- invoiceplane_data:/var/www/html/uploads
environment:
- TZ=utc
- MYSQL_HOST=mariadb_10_4
- MYSQL_USER=InvoicePlane
- MYSQL_PASSWORD=invoiceplane
- MYSQL_DB=InvoicePlane
- IP_URL=http://invoiceplane.docker.local
- DISABLE_SETUP=true
deploy:
replicas: 1
restart_policy:
condition: on-failure
labels:
- "traefik.http.routers.invoiceplane.rule=Host(`invoiceplane.docker.local`)"
- "traefik.http.routers.invoiceplane.service=invoiceplane"
- "traefik.http.services.invoiceplane.loadbalancer.server.port=80"
mariadb_10_4:
# MySQL 5.7
image: mariadb:10.4.10
volumes:
- mariadb_10_4:/var/lib/mysql
environment:
- MYSQL_ROOT_PASSWORD=mysql_password
- MYSQL_DATABASE=InvoicePlane
- MYSQL_USER=InvoicePlane
- MYSQL_PASSWORD=invoiceplane
deploy:
mode: replicated
replicas: 1
labels:
- "traefik.enable=false"