From c1e7fd38c0c0556e6ffc9ca4878eb62d1f467c20 Mon Sep 17 00:00:00 2001 From: Alexandre <44178713+alexbelgium@users.noreply.github.com> Date: Tue, 23 Apr 2024 22:58:49 +0200 Subject: [PATCH] Update Dockerfile --- zzz_draft_birdnet-pi/Dockerfile | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/zzz_draft_birdnet-pi/Dockerfile b/zzz_draft_birdnet-pi/Dockerfile index ff8c7fffa..f2b4d601c 100644 --- a/zzz_draft_birdnet-pi/Dockerfile +++ b/zzz_draft_birdnet-pi/Dockerfile @@ -17,7 +17,6 @@ ARG BUILD_VERSION ARG BUILD_FROM FROM ${BUILD_FROM} -SHELL ["/bin/bash", "-o", "pipefail", "-c"] ENV DEBIAN_FRONTEND noninteractive ENV HOME="/home/birdnet" @@ -30,12 +29,7 @@ RUN \ groupadd --gid 1000 birdnet && useradd --uid 1000 --gid birdnet --shell /bin/bash --create-home birdnet && \ echo "birdnet ALL=(ALL) NOPASSWD:ALL" >> /etc/sudoers && \ \ - if type sudo 2>/dev/null; then \ - echo "The sudo command already exists... Skipping."; \ - else \ - echo "#!/bin/sh\n\${@}" > /usr/sbin/sudo; \ - chmod +x /usr/sbin/sudo; \ - fi && \ + chown root:root /etc/sudoers chown root:root /usr/bin/sudo && \ chmod 4755 /usr/bin/sudo && \ \ @@ -47,8 +41,7 @@ RUN \ sed -i "s|apt |apt-get |g" /newinstaller.sh && \ #sed -i "s|sudo -n true|true|g" /newinstaller.sh && \ #sed -i "s|sudo|#sudo|g" /newinstaller.sh && \ - cat /newinstaller.sh && \ - sudo -u birdnet -E -s /bin/bash -c "/newinstaller.sh" + sudo -u birdnet -s /bin/bash -c "/newinstaller.sh" ################## # 2 Modify Image #