Skip to content

Commit

Permalink
issue 62 fix (#63)
Browse files Browse the repository at this point in the history
Adding the HOME variable makes the Docker build process create and use the /httpbin/.local folder in both build and runtime. Without this, the Dockerfile creates a folder /root/.local and uses it while the specified user is root. However, in the case of a user override with runAsUser or a similar command, /root is no longer the home directory and is not accessible to the non-root user. This line fixes this issue. It has been fixed and tested locally.
  • Loading branch information
VBranimir authored Oct 28, 2024
1 parent 4a110b6 commit 372a20c
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,12 @@ LABEL description="A simple HTTP service."

ENV LC_ALL=C.UTF-8
ENV LANG=C.UTF-8
ENV HOME=/httpbin

WORKDIR /httpbin

RUN apt update -y && apt install python3-pip libssl-dev libffi-dev git -y && pip3 install --no-cache-dir pipenv

WORKDIR /httpbin
ADD . .
RUN pipenv sync

Expand Down

0 comments on commit 372a20c

Please sign in to comment.