-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdns-docker-compose.yml
37 lines (36 loc) · 1.16 KB
/
dns-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
version: "3.8"
services:
localdns:
container_name: localdns
network_mode: bridge #use default bridge network instead of implicit docker-compose custom network
image: jpillora/dnsmasq
restart: always
ports:
- "53:53/udp"
- "5380:8080"
environment:
MAPPED_HOSTS: "/etc/docker-dns/hosts.json"
HTTP_USER: "user"
HTTP_PASS: "user"
volumes:
- ./dnsmasq/dnsmasq.conf:/etc/dnsmasq.conf
nginx:
container_name: nginx
image: nginx:alpine
#network_mode: bridge #use default bridge network instead of implicit docker-compose custom network
restart: always
volumes:
- ./nginx/certs:/etc/nginx/certs
- ./nginx/conf.d:/etc/nginx/conf.d
- ./nginx/nginx.conf:/etc/nginx/nginx.conf
ports:
- "80:80"
- "443:443"
demo.docker: #postfix .docker to resolve in internal network
container_name: demo
image: nginxdemos/hello
restart: always
networks:
default:
external:
name: dockerdev