Please follow the below template, it will help us to help you!
Actual Behaviour:
Running Pihole with docker compose w/ podman. Starts with following errors:
pihole | install: cannot create regular file '/etc/pihole/dhcp.leases': Permission denied
pihole | chown: cannot access '/etc/pihole/dhcp.leases': No such file or directory
pihole | chown: changing ownership of '/etc/pihole': Permission denied
pihole | chmod: cannot access '/etc/pihole/dhcp.leases': No such file or directory
pihole | Stopping pihole-FTL
pihole | pihole-FTL: no process found
Here is my docker-compose.yml:
pihole:
container_name: pihole
image: pihole/pihole:latest
networks:
pihole_network:
ipv4_address: '192.168.50.20'
# For DHCP it is recommended to remove these ports and instead add: network_mode: "host"
ports:
- "53:53/tcp"
- "53:53/udp"
- "67:67/udp" # Only required if you are using Pi-hole as your DHCP server
- "80:80/tcp"
- "443:443/tcp"
- "80:80/tcp"
environment:
TZ: 'America/Chicago'
WEBPASSWORD: "*************"
# Volumes store your data between container upgrades
volumes:
- /home/svon/podman/pihole/etc-pihole:/etc/pihole
- /home/svon/podman/pihole/etc-dnsmasq.d:/etc/dnsmasq.d
cap_add:
- NET_ADMIN # Required if you are using Pi-hole as your DHCP server, else not needed
restart: unless-stopped
networks:
pihole_network:
driver: macvlan
driver_opts:
parent: enp7s0
ipam:
config:
- subnet: 192.168.50.0/24
gateway: 192.168.50.1
pihole directories on podman host are 755. in the container:
drwxr-xr-x. 2 1000 pihole 6 Jan 10 20:23 pihole/
I'm quite new to containers in general so apologies if I'm missing something basic or if I can provide more info. Thanks