Skip to content

Commit

Permalink
fix: use root user to install code-server
Browse files Browse the repository at this point in the history
  • Loading branch information
Eric-2369 committed Oct 14, 2024
1 parent 02e5727 commit 4cc84cd
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions debian12-codeserver/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@ RUN apt-get update \
RUN useradd --create-home --shell /bin/bash eric2369 \
&& echo "eric2369 ALL=(ALL) NOPASSWD:ALL" >> /etc/sudoers.d/nopasswd

USER eric2369

ARG TARGETPLATFORM
RUN set -eux; \
case "${TARGETPLATFORM}" in \
Expand All @@ -25,9 +23,11 @@ RUN set -eux; \
;; \
esac; \
curl "${URL}" --location --output /home/eric2369/code-server.deb; \
sudo dpkg -i /home/eric2369/code-server.deb; \
dpkg -i /home/eric2369/code-server.deb; \
rm /home/eric2369/code-server.deb

USER eric2369

RUN set -eux; \
case "${TARGETPLATFORM}" in \
"linux/amd64") \
Expand Down

0 comments on commit 4cc84cd

Please sign in to comment.