0ab1c043d6
Signed-off-by: TuDatTr <tuan-dat.tran@tudattr.dev>
86 lines
2.4 KiB
YAML
86 lines
2.4 KiB
YAML
version: '3'
|
|
services:
|
|
traefik:
|
|
container_name: traefik
|
|
image: traefik:v2.5
|
|
networks:
|
|
- compose_net
|
|
volumes:
|
|
- "/etc/localtime:/etc/localtime:ro"
|
|
- "/var/run/docker.sock:/var/run/docker.sock:ro"
|
|
- {{ docker_dir }}/traefik/traefik.yml:/etc/traefik/traefik.yml
|
|
ports:
|
|
- 80:80
|
|
- 8080:8080
|
|
labels:
|
|
- "traefik.enable=true"
|
|
- "traefik.http.routers.traefik.rule=Host(`traefik.{{local_domain}}`)"
|
|
- "traefik.http.routers.traefik.entrypoints=web"
|
|
- "traefik.http.services.traefik.loadbalancer.server.port=80"
|
|
ddns-updater:
|
|
container_name: ddns-updater
|
|
image: "ghcr.io/qdm12/ddns-updater"
|
|
networks:
|
|
- compose_net
|
|
volumes:
|
|
- {{ docker_dir }}/ddns-updater/data/:/updater/data/
|
|
ports:
|
|
- 8000:8000/tcp
|
|
restart: unless-stopped
|
|
homeassistant:
|
|
container_name: homeassistant
|
|
image: "ghcr.io/home-assistant/home-assistant:stable"
|
|
networks:
|
|
- compose_net
|
|
volumes:
|
|
- /etc/localtime:/etc/localtime:ro
|
|
- {{ docker_dir }}/home-assistant/config/:/config/
|
|
restart: unless-stopped
|
|
privileged: true
|
|
network_mode: host
|
|
labels:
|
|
- "traefik.enable=true"
|
|
- "traefik.http.routers.homeassistant.rule=Host(`hass.{{local_domain}}`)"
|
|
- "traefik.http.routers.homeassistant.entrypoints=web"
|
|
- "traefik.http.services.homeassistant.loadbalancer.server.port=8123"
|
|
pihole:
|
|
container_name: pihole
|
|
image: pihole/pihole:latest
|
|
networks:
|
|
- compose_net
|
|
ports:
|
|
- "53:53/tcp"
|
|
- "53:53/udp"
|
|
- "67:67/udp"
|
|
- "8089:80/tcp"
|
|
environment:
|
|
- "TZ=Europe/Berlin"
|
|
- "WEBPASSWORD=a"
|
|
- "ServerIP=192.168.20.11"
|
|
- "INTERFACE=eth0"
|
|
- "DNS1=1.1.1.1"
|
|
- "DNS1=1.0.0.1"
|
|
volumes:
|
|
- "{{ docker_dir }}/pihole/etc-pihole/:/etc/pihole/"
|
|
- "{{ docker_dir }}/pihole/etc-dnsmasq.d/:/etc/dnsmasq.d/"
|
|
dns:
|
|
- 127.0.0.1
|
|
- 1.1.1.1
|
|
cap_add:
|
|
- NET_ADMIN
|
|
restart: unless-stopped
|
|
labels:
|
|
- "traefik.enable=true"
|
|
- "traefik.http.routers.pihole.rule=Host(`pihole.{{local_domain}}`)"
|
|
- "traefik.http.routers.pihole.entrypoints=web"
|
|
- "traefik.http.services.pihole.loadbalancer.server.port=8089"
|
|
|
|
networks:
|
|
compose_net:
|
|
driver: bridge
|
|
ipam:
|
|
driver: default
|
|
config:
|
|
- subnet: 172.16.69.0/24
|
|
gateway: 172.16.69.1
|