From 666994badb587b428fffaa0760b11bbd8d421d92 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ond=C5=99ej=20Sur=C3=BD?= Date: Sat, 1 Mar 2025 07:24:14 +0100 Subject: [PATCH] Use explicit UID/GID 53 (changeable with ARG) Closes: #62, #60 --- Dockerfile | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 48973e8..4d81788 100644 --- a/Dockerfile +++ b/Dockerfile @@ -4,6 +4,9 @@ LABEL org.opencontainers.image.authors="BIND 9 Developers " ENV DEBIAN_FRONTEND noninteractive ENV LC_ALL C.UTF-8 +ARG UID=53 +ARG GID=53 + ARG BIND9_VERSION=9.21.5 ARG BIND9_CHECKSUM=afe46892950a6676fe198b90aa25b7b856cdc468997fac135dc260f313d6455f @@ -74,7 +77,7 @@ RUN cd /usr/src && \ rm -rf /usr/src # Create user and group -RUN addgroup -S bind && adduser -S -H -h /var/cache/bind -G bind bind +RUN addgroup -S -g ${GID} bind && adduser -S -u ${UID} -H -h /var/cache/bind -G bind bind # Create default configuration file RUN mkdir -p /etc/bind && chown root:bind /etc/bind/ && chmod 755 /etc/bind