From d330df8f7dbccb788a38d92c2bbd4eb96e2c25ca Mon Sep 17 00:00:00 2001 From: "Mario V." Date: Fri, 21 Feb 2025 10:48:48 +0100 Subject: [PATCH 1/4] Update Dockerfile --- Dockerfile | 25 ++++++++++++++++--------- 1 file changed, 16 insertions(+), 9 deletions(-) diff --git a/Dockerfile b/Dockerfile index 41fe67d..26e49b3 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,13 +1,20 @@ -#ARG PIHOLE_VERSION +# Use the new Alpine-based Pi-hole image FROM pihole/pihole:2025.02.1 -#RUN apk update && apk add -y unbound wget -#COPY pihole-unbound/lighttpd-external.conf /etc/lighttpd/external.conf -#COPY pihole-unbound/unbound-pihole.conf /etc/unbound/unbound.conf.d/pi-hole.conf -#COPY pihole-unbound/99-edns.conf /etc/dnsmasq.d/99-edns.conf -#RUN mkdir -p /etc/services.d/unbound -#COPY pihole-unbound/unbound-run /etc/services.d/unbound/run -#RUN wget https://www.internic.net/domain/named.root -qO- | sudo tee /var/lib/unbound/root.hints +# Update package list and install unbound and wget +RUN apk update && apk add unbound wget +# Copy configuration files +COPY pihole-unbound/lighttpd-external.conf /etc/lighttpd/external.conf +COPY pihole-unbound/unbound-pihole.conf /etc/unbound/unbound.conf.d/pi-hole.conf +COPY pihole-unbound/99-edns.conf /etc/dnsmasq.d/99-edns.conf -ENTRYPOINT ./s6-init +# Create the services directory and copy the run script +RUN mkdir -p /etc/services.d/unbound +COPY pihole-unbound/unbound-run /etc/services.d/unbound/run + +# Download the root hints file for unbound +RUN wget https://www.internic.net/domain/named.root -qO- > /var/lib/unbound/root.hints + +# Set the entrypoint to the s6 initialization script +ENTRYPOINT ["/s6-init"] From f33379a463f75bc7ba2fa11c4404e1ff3b58b8d9 Mon Sep 17 00:00:00 2001 From: "Mario V." Date: Fri, 21 Feb 2025 10:51:13 +0100 Subject: [PATCH 2/4] Update Dockerfile --- Dockerfile | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 26e49b3..3124453 100644 --- a/Dockerfile +++ b/Dockerfile @@ -13,8 +13,12 @@ COPY pihole-unbound/99-edns.conf /etc/dnsmasq.d/99-edns.conf RUN mkdir -p /etc/services.d/unbound COPY pihole-unbound/unbound-run /etc/services.d/unbound/run +# Create the unbound directory and set permissions +RUN mkdir -p /var/lib/unbound && \ + chown pihole:pihole /var/lib/unbound + # Download the root hints file for unbound -RUN wget https://www.internic.net/domain/named.root -qO- > /var/lib/unbound/root.hints +RUN wget https://www.internic.net/domain/named.root -qO /var/lib/unbound/root.hints # Set the entrypoint to the s6 initialization script ENTRYPOINT ["/s6-init"] From f49ce98c16ffe2bfb96131cc46892242bbe50274 Mon Sep 17 00:00:00 2001 From: "Mario V." Date: Fri, 21 Feb 2025 12:28:03 +0100 Subject: [PATCH 3/4] Update Dockerfile --- Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 3124453..12bb611 100644 --- a/Dockerfile +++ b/Dockerfile @@ -21,4 +21,4 @@ RUN mkdir -p /var/lib/unbound && \ RUN wget https://www.internic.net/domain/named.root -qO /var/lib/unbound/root.hints # Set the entrypoint to the s6 initialization script -ENTRYPOINT ["/s6-init"] +ENTRYPOINT ["/init"] From 014fae957729dc3c859bd2ead488e38f20245146 Mon Sep 17 00:00:00 2001 From: "Mario V." Date: Fri, 21 Feb 2025 12:31:33 +0100 Subject: [PATCH 4/4] Update Dockerfile --- Dockerfile | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index 12bb611..b676a19 100644 --- a/Dockerfile +++ b/Dockerfile @@ -20,5 +20,4 @@ RUN mkdir -p /var/lib/unbound && \ # Download the root hints file for unbound RUN wget https://www.internic.net/domain/named.root -qO /var/lib/unbound/root.hints -# Set the entrypoint to the s6 initialization script -ENTRYPOINT ["/init"] +ENTRYPOINT ["start.sh"]