generated from itk-dev/drupal-11-template
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.server.yml
59 lines (56 loc) · 1.61 KB
/
docker-compose.server.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
# itk-version: 3.2.1
networks:
frontend:
external: true
app:
driver: bridge
internal: false
services:
phpfpm:
image: itkdev/php8.3-fpm:alpine
restart: unless-stopped
networks:
- app
extra_hosts:
- "host.docker.internal:host-gateway"
environment:
- PHP_MAX_EXECUTION_TIME=30
- PHP_MEMORY_LIMIT=128M
- COMPOSER_VERSION=2
depends_on:
- memcached
volumes:
- .:/app
nginx:
image: nginxinc/nginx-unprivileged:alpine
restart: unless-stopped
networks:
- app
- frontend
depends_on:
- phpfpm
volumes:
- ./.docker/templates:/etc/nginx/templates:ro
- ./.docker/nginx.conf:/etc/nginx/nginx.conf:ro
- .:/app
environment:
NGINX_FPM_SERVICE: ${COMPOSE_PROJECT_NAME}-phpfpm-1:9000
NGINX_WEB_ROOT: /app/web
NGINX_PORT: 8080
NGINX_MAX_BODY_SIZE: 5M
labels:
- "traefik.enable=true"
- "traefik.docker.network=frontend"
- "traefik.http.routers.${COMPOSE_PROJECT_NAME}-http.rule=Host(`${COMPOSE_SERVER_DOMAIN}`)"
- "traefik.http.routers.${COMPOSE_PROJECT_NAME}-http.entrypoints=web"
- "traefik.http.routers.${COMPOSE_PROJECT_NAME}-http.middlewares=redirect-to-https"
- "traefik.http.middlewares.redirect-to-https.redirectscheme.scheme=https"
- "traefik.http.routers.${COMPOSE_PROJECT_NAME}.rule=Host(`${COMPOSE_SERVER_DOMAIN}`)"
- "traefik.http.routers.${COMPOSE_PROJECT_NAME}.entrypoints=websecure"
memcached:
image: 'memcached:latest'
restart: unless-stopped
networks:
- app
environment:
- MEMCACHED_CACHE_SIZE=64