-
Notifications
You must be signed in to change notification settings - Fork 4
/
docker-compose.yml
80 lines (76 loc) · 2.56 KB
/
docker-compose.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
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
version: "2.1"
services:
app:
image: kenayagi/odoo:14.0
restart: always
volumes:
- odoodata:/var/lib/odoo
networks:
- traefik
- net
depends_on:
db:
condition: service_healthy
environment:
- TZ=Europe/Rome
- ODOO_ADMIN_PASSWD=Db4dm1nSup3rS3cr3tP4ssw0rD
- ODOO_DB=installationid
- POSTGRES_USER=odoo
- POSTGRES_PASSWORD=PassWooorD
labels:
- "traefik.enable=true"
- "traefik.http.services.odooidfront.loadbalancer.server.port=8069"
- "traefik.http.routers.odooidfront.service=odooidfront"
- "traefik.http.routers.odooidfront.middlewares=odooid-compress"
- "traefik.http.routers.odooidfront.rule=Host(`odoo.domain.com`)"
- "traefik.http.routers.odooidfront.tls.certresolver=le"
- "traefik.http.services.odooidmng.loadbalancer.server.port=8069"
- "traefik.http.routers.odooidmng.service=odooidmng"
- "traefik.http.routers.odooidmng.middlewares=odooid-ipwl,odooid-compress"
- "traefik.http.routers.odooidmng.rule=Host(`odoo.domain.com`) && Path(`/web/database/manager/`)"
- "traefik.http.routers.odooidmng.tls.certresolver=le"
- "traefik.http.services.odooidpoll.loadbalancer.server.port=8072"
- "traefik.http.routers.odooidpoll.service=odooidpoll"
- "traefik.http.routers.odooidpoll.middlewares=odooid-compress"
- "traefik.http.routers.odooidpoll.rule=Host(`odoo.domain.com`) && PathPrefix(`/longpolling`)"
- "traefik.http.routers.odooidpoll.tls.certresolver=le"
- "traefik.http.middlewares.odooid-ipwl.ipwhitelist.sourcerange=127.0.0.1/32, 192.168.0.0/16"
- "traefik.http.middlewares.odooid-compress.compress=true"
db:
image: postgres:14.2
# command: -c "synchronous_commit=off" -c "full_page_writes=off" -c "shared_buffers=512MB"
stop_signal: SIGINT
stop_grace_period: 3m
restart: always
volumes:
- pgdata:/var/lib/postgresql/data
networks:
- net
environment:
- TZ=Europe/Rome
- ODOO_DB=installationid
- POSTGRES_USER=odoo
- POSTGRES_PASSWORD=Pa5sWo0orD
healthcheck:
test: ["CMD-SHELL", "pg_isready -U $$POSTGRES_USER -d $$ODOO_DB"]
interval: 10s
timeout: 5s
retries: 5
volumes:
# Storage for Odoo data (filestore, etc.)
odoodata:
driver_opts:
type: none
o: bind
device: /srv/odoodata/installationid
# Storage for PostgreSQL database
pgdata:
driver_opts:
type: none
o: bind
device: /srv/postgres/installationid
networks:
net:
traefik:
external: true
name: traefik