forked from plone/volto
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
62 lines (59 loc) · 2.24 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
version: '3.3'
services:
backend:
image: plone/plone-backend:6.0.5
# Plone 5.2 series can be used too
# image: plone/plone-backend:5.2.10
ports:
- '8080:8080'
environment:
- SITE=Plone
- 'PROFILES=plone.volto:default-homepage'
labels:
- traefik.enable=true
# SERVICE
- traefik.http.services.plone-backend.loadbalancer.server.port=8080
# Plone API
- traefik.http.routers.backend.rule=Host(`plone.localhost`) && PathPrefix(`/++api++`)
- traefik.http.routers.backend.service=plone-backend
- "traefik.http.middlewares.backend.replacepathregex.regex=^/\\+\\+api\\+\\+($$|/.*)"
- "traefik.http.middlewares.backend.replacepathregex.replacement=/VirtualHostBase/http/plone.localhost/Plone/++api++/VirtualHostRoot/$$1"
- traefik.http.routers.backend.middlewares=gzip,backend
frontend:
image: 'plone/plone-frontend:latest'
ports:
- '3000:3000'
restart: always
environment:
# These are needed in a Docker environment since the
# routing needs to be amended. You can point to the
# internal network alias.
RAZZLE_INTERNAL_API_PATH: http://backend:8080/Plone
# This last is not required if a reverse proxy is in the stack
RAZZLE_DEV_PROXY_API_PATH: http://backend:8080/Plone
depends_on:
- backend
labels:
- traefik.enable=true
# SERVICE
- traefik.http.services.plone-frontend.loadbalancer.server.port=3000
# HOSTS: Main
- traefik.http.routers.frontend.rule=Host(`plone.localhost`)
- traefik.http.routers.frontend.service=plone-frontend
- traefik.http.routers.frontend.middlewares=gzip
reverse-proxy:
# The official v2 Traefik docker image
image: traefik:v2.9
# Enables the web UI and tells Traefik to listen to docker
command: --api.insecure=true --providers.docker
ports:
# The HTTP port
- "80:80"
# The Web UI (enabled by --api.insecure=true)
- "8888:8080"
volumes:
# So that Traefik can listen to the Docker events
- /var/run/docker.sock:/var/run/docker.sock:ro
labels:
- traefik.http.middlewares.gzip.compress=true
- traefik.http.middlewares.gzip.compress.excludedcontenttypes=image/png, image/jpeg, font/woff2