-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
78 lines (78 loc) · 2.06 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
# For more information: https://phpfusion.com/ (to be announced later)
version: '3'
services:
phpfusion-www:
build:
context: ./bin/${APP_PHPVERSION}
container_name: '${APP_NAME}-${APP_PHPVERSION}'
restart: 'always'
ports:
- '${APP_HOST_PORT:-80}:80'
- '${APP_HOST_SECURE_PORT:-443}:443'
networks:
- phpfusion-docker
volumes:
- ${DOCUMENT_ROOT-./public_html}:/var/www/html
- ${PHP_INI-./config/php/php.ini}:/usr/local/etc/php/php.ini
- ${PHP_INI-./config/php/opcache.ini}:/usr/local/etc/php/conf.d/opcache.ini
- ${VHOSTS_DIR-./config/vhosts}:/etc/apache2/sites-enabled
- ${LOG_DIR-./logs/apache2}:/var/log/apache2
environment:
PMA_PORT: ${APP_HOST_PMA_PORT}
PHP_OPCACHE_VALIDATE_TIMESTAMPS: 1
mysql:
image: 'mysql/mysql-server:8.0'
ports:
- ${FORWARD_DB_PORT:-3306}:3306
environment:
MYSQL_ROOT_PASSWORD: "${DB_PASSWORD}"
MYSQL_ROOT_HOT: "%"
MYSQL_DATABASE: "${DB_DATABASE}"
MYSQL_USER: "${DB_USERNAME}"
MYSQL_PASSWORD: "${DB_PASSWORD}"
volumes:
- 'phpfusion-mysql:/var/lib/mysql'
networks:
- phpfusion-docker
healthcheck:
test: [ "CMD", "mysqladmin", "ping", "-p${DB_PASSWORD}" ]
retries: 3
timeout: 5s
phpmyadmin:
depends_on:
- mysql
image: 'phpmyadmin/phpmyadmin'
ports:
- 8001:80
environment:
- PMA_HOST=mysql
- PMA_PORT=${DB_PORT:-3306}
networks:
- phpfusion-docker
redis:
image: "redis:alpine"
ports:
- '${FORWARD_REDIS_PORT:-6379}:6379'
volumes:
- 'phpfusion-redis:/data'
networks:
- phpfusion-docker
healthcheck:
test: [ "CMD", "redis-cli", "ping" ]
retries: 3
timeout: 5s
mailhog:
image: 'mailhog/mailhog:latest'
ports:
- '${FORWARD_MAILHOG_PORT:-1025}:1025'
- '${FORWARD_MAILHOG_DASHBOARD_PORT:-8025}:8025'
networks:
- phpfusion-docker
networks:
phpfusion-docker:
driver: bridge
volumes:
phpfusion-mysql:
driver: local
phpfusion-redis:
driver: local