DockerComposeCollection

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | README

docker-compose.yaml (2105B)


      1 # More info at https://github.com/pi-hole/docker-pi-hole/ and https://docs.pi-hole.net/
      2 services:
      3   pihole:
      4     container_name: pihole
      5     image: pihole/pihole:latest
      6     ports:
      7       # DNS Ports
      8       - "53:53/tcp"
      9       - "53:53/udp"
     10       # Default HTTP Port
     11       - "80:80/tcp"
     12       # Default HTTPs Port. FTL will generate a self-signed certificate
     13       - "443:443/tcp"
     14       # Uncomment the line below if you are using Pi-hole as your DHCP server
     15       #- "67:67/udp"
     16       # Uncomment the line below if you are using Pi-hole as your NTP server
     17       #- "123:123/udp"
     18     environment:
     19       # Set the appropriate timezone for your location (https://en.wikipedia.org/wiki/List_of_tz_database_time_zones), e.g:
     20       TZ: 'Asia/Tokyo'
     21       # Set a password to access the web interface. Not setting one will result in a random password being assigned
     22       FTLCONF_webserver_api_password: 'correct horse battery staple'
     23       # If using Docker's default `bridge` network setting the dns listening mode should be set to 'all'
     24       FTLCONF_dns_listeningMode: 'all'
     25     # Volumes store your data between container upgrades
     26     volumes:
     27       # For persisting Pi-hole's databases and common configuration file
     28       - './etc-pihole:/etc/pihole'
     29       # Uncomment the below if you have custom dnsmasq config files that you want to persist. Not needed for most starting fresh with Pi-hole v6. If you're upgrading from v5 you and have used this directory before, you should keep it enabled for the first v6 container start to allow for a complete migration. It can be removed afterwards. Needs environment variable FTLCONF_misc_etc_dnsmasq_d: 'true'
     30       #- './etc-dnsmasq.d:/etc/dnsmasq.d'
     31     cap_add:
     32       # See https://github.com/pi-hole/docker-pi-hole#note-on-capabilities
     33       # Required if you are using Pi-hole as your DHCP server, else not needed
     34       - NET_ADMIN
     35       # Required if you are using Pi-hole as your NTP client to be able to set the host's system time
     36       - SYS_TIME
     37       # Optional, if Pi-hole should get some more processing time
     38       - SYS_NICE
     39     restart: unless-stopped