-
Notifications
You must be signed in to change notification settings - Fork 8
/
docker-compose.yaml
67 lines (67 loc) · 2.19 KB
/
docker-compose.yaml
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
version: "3.9"
services:
mitmdump:
image: mitmproxy/mitmproxy
hostname: mitmproxy
env_file: settings.env
volumes:
- ./data/:/data/
- type: bind
source: ./mitm/log_http_requests.py
target: /log_http_requests.py
- type: bind
source: ./logs/mitm/http.log
target: /http.log
command: sh -c "pip install ipwhois requests && mitmdump -q -s /log_http_requests.py --mode reverse:http://nginx-server:8000 -p 30001 --set block_global=false"
server:
image: nginx
hostname: nginx-server
ports:
- "443:443"
- "8443:443"
- "80:80"
- "8080:80"
# add your own port mapping here if you want to listen on other non-standard ports too
volumes:
- ./www/:/var/www/html/
- type: bind
source: ./conf/nginx/nginx.conf
target: /etc/nginx/conf.d/default.conf
- ./keys/:/etc/nginx/keys/
- ./conf/nginx/docker-entrypoint.d/:/docker-entrypoint.d/
depends_on:
- mitmdump
links:
- php
php:
image: php:7-fpm
env_file: settings.env
volumes:
- ./data/:/data/
- ./www/:/var/www/html/
dns:
image: ubuntu/bind9:9.16-20.04_beta
restart: always
ports:
- "53:53/udp"
- "53:53/tcp"
env_file: settings.env
volumes:
- ./data/:/data/
- type: bind
source: ./dns/monitor.py
target: /monitor.py
- type: bind
source: ./conf/bind9/named.conf.local
target: /etc/bind/named.conf.local
- type: bind
source: ./conf/bind9/named.conf.options
target: /etc/bind/named.conf.options
- type: bind
source: ./conf/bind9/named.conf
target: /etc/bind/named.conf
- type: bind
source: ./dns/zonefile.db
target: /var/cache/bind/zonefile.db
- ./logs/dns/:/var/log/named/
command: sh -c 'touch /var/log/named/queries.log && chown bind:bind /var/log/named/queries.log && apt -y update && apt -y -o Dpkg::Options::="--force-confdef" -o Dpkg::Options::="--force-confold" upgrade && apt install -y python3-pip && pip install requests && chown bind:bind /var/log/named/ && (python3 /monitor.py &) && /usr/sbin/named -f -c /etc/bind/named.conf -u bind'