/system/device-mode
update container=yes
/system/device-mode
print
/interface veth
add address=192.168.254.2/24 gateway=192.168.254.1 gateway6="" name=Veth-Pihole
/interface bridge
add admin-mac=02:F1:38:46:46:E2 auto-mac=no name=Bridge-Docker
/interface bridge port
add bridge=Bridge-Docker interface=Veth-Pihole
/ip address
add address=192.168.254.1/24 interface=Bridge-Docker network=192.168.254.0
/ip firewall nat
add action=masquerade chain=srcnat src-address=192.168.254.0/24
/container envs
add key=TZ name=pihole_env value=Europe/Kyiv
add key=WEBPASSWORD name=pihole_env value=10203040
add key=DNSMASQ_USER name=pihole_env value=root
/container mounts
add dst=/etc/pihole name=etc_pihole src=/slot1/etc
add dst=/etc/dnsmasq.d name=dnsmasq_pihole src=/slot1/etc-dnsmasq.d
/container config
set registry-url=https://registry-1.docker.io tmpdir=/slot1/pull
/container
add remote-image=pihole/pihole:latest interface=Veth-Pihole root-dir=/slot1/pihole mounts=dnsmasq_pihole,etc_pihole envlist=pihole_env
/ip firewall nat
add action=dst-nat chain=dstnat dst-address=192.168.5.254 dst-port=8080 \
protocol=tcp to-addresses=192.168.254.2 to-ports=80
/ip firewall nat
add action=dst-nat chain=dstnat dst-address=192.168.5.254 dst-port=53 \
protocol=udp to-addresses=192.168.254.2