-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
106 lines (94 loc) · 2.69 KB
/
docker-compose.yml
File metadata and controls
106 lines (94 loc) · 2.69 KB
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
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
version: "3.8"
name: ${APP_NAME}
services:
# PHP APPS
php_app:
container_name: ${APP_NAME}
image: ${APP_NAME}/php
build:
context: .
dockerfile: ./dockerfiles/Dockerfile
args:
- COMPOSER_VERSION=latest
- XDEBUG_VERSION=latest
volumes:
- "php_app:/var/www/html"
- "./logs/xdebug:/var/log/xdebug"
- "./volumes/www-home:/home/www-data"
- "./ssl/ca/ca.crt:/usr/local/share/cert_install/ca.crt"
- ./volumes/mitmproxy:/usr/local/share/cert_install/mitmproxy
# Uncomment for ssh These files will be copied upon
# - "./conf/ssh/config:/home/www-data/.ssh_settings/config"
# Replace ssh keys here
# - "~/.ssh/pc_magas.pub:/home/www-data/.ssh_settings/pc_magas.pub"
# - "~/.ssh/pc_magas:/home/www-data/.ssh_settings/pc_magas"
networks:
default:
env_file: env/php.env
extra_hosts:
- "host.docker.internal:host-gateway"
# Supportive services
nginx:
container_name: ${APP_NAME}-nginx
image: nginx
networks:
default:
ipv4_address: ${IP_BASE}.2
volumes:
- "php_app:/var/www/html"
- "./conf/nginx/nginx.conf:/etc/nginx/nginx.conf:ro"
- "./ssl/certs/www.crt:/etc/nginx/ssl/www.crt:ro"
- "./ssl/certs/www.key:/etc/nginx/ssl/www.key:ro"
mariadb:
# Replace with your own
image: mariadb:10.4
container_name: ${APP_NAME}-mariadb
command:
--max_allowed_packet=64M
--optimizer_use_condition_selectivity=1
--optimizer_switch="rowid_filter=off"
networks:
default:
ipv4_address: ${IP_BASE}.3
env_file: env/mysql_maria.env
volumes:
- ./volumes/db:/var/lib/mysql
- ./provision/mariadb/create-test-db.sh:/docker-entrypoint-initdb.d/create-test-db.sh
mailpit:
image: axllent/mailpit
container_name: mailpit
restart: always
volumes:
- ./volumes/mailpit:/data
networks:
default:
ipv4_address: ${IP_BASE}.6
environment:
MP_MAX_MESSAGES: 5000
MP_DATA_FILE: /data/mailpit.db
MP_SMTP_AUTH_ACCEPT_ANY: 1
MP_SMTP_AUTH_ALLOW_INSECURE: 1
mitmproxy:
image: mitmproxy/mitmproxy
command: mitmweb --listen-host 0.0.0.0 --web-host 0.0.0.0 --no-web-open-browser --set console_eventlog_verbosity=debug
stdin_open: true
tty: true
networks:
default:
ipv4_address: ${IP_BASE}.7
volumes:
- ./volumes/mitmproxy:/home/mitmproxy/.mitmproxy
volumes:
php_app:
driver: local
driver_opts:
type: none
o: bind
device: ${PHP_APP_PATH}
networks:
default:
ipam:
config:
- subnet: ${IP_BASE}.0/24
gateway: ${IP_BASE}.1
ip_range: ${IP_BASE}.128/25