-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
69 lines (63 loc) · 1.57 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
version: '3.5'
services:
php:
container_name: ${PROJECT_NAME}_php
build:
context: .
dockerfile: ./.docker/containers/php/Dockerfile
depends_on:
- database
env_file:
- .env
networks:
service:
aliases:
- pod
environment:
- ENV=/home/www-data/.ashrc
volumes:
- ./:/srv/app/:rw
- ./.docker/containers/php/www.conf:/etc/php8.1.3/php-fpm.conf
- ./.docker/containers/php/php.ini:/usr/local/etc/php/php.ini
command: --define opcache.validate_timestamps=On
nginx:
container_name: ${PROJECT_NAME}_nginx
depends_on:
- php
image: nginx:1.20-alpine
labels:
- "traefik.enable=true"
- "traefik.docker.network=traefik"
- "traefik.http.routers.${PROJECT_NAME}.rule=Host(`${PROJECT_NAME}.traefik.me`)"
- "traefik.http.routers.${PROJECT_NAME}.tls=true"
- "traefik.http.services.${PROJECT_NAME}.loadbalancer.server.port=8080"
networks:
- service
- traefik
volumes:
- ./public:/srv/app/public:ro
- ./.docker/containers/nginx/nginx.conf:/etc/nginx/conf.d/default.conf
database:
container_name: ${PROJECT_NAME}_database
image: mariadb:10.4.19
env_file:
- .env
networks:
- service
ports:
- ${DATABASE_PORT-3306}:3306
volumes:
- database_docker:/var/lib/mysql
qa:
container_name: ${PROJECT_NAME}_qa
image: jakzal/phpqa:latest
volumes:
database_docker: {}
certs: {}
networks:
service:
name: service
external: true
traefik:
name: traefik
external: true