Skip to content

Commit

Permalink
fix: add new user in container for tests
Browse files Browse the repository at this point in the history
  • Loading branch information
Alexander Pikeev committed Dec 1, 2024
1 parent f84f7d2 commit e99a293
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions build/tests/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -45,18 +45,21 @@ ENV LOG_LEVEL=${GOTENBERG_LOG_LEVEL}
ENV GOTENBERG_API_BASIC_AUTH_USERNAME=foo
ENV GOTENBERG_API_BASIC_AUTH_PASSWORD=bar



# Define our workding outside of $GOPATH (we're using go modules).
WORKDIR /tests

RUN adduser --disabled-password --gecos '' testuser
RUN chown testuser /tests

# Copy our module dependencies definitions.
COPY go.mod .
COPY go.sum .

# Install module dependencies.
RUN go mod download

RUN adduser --disabled-password --gecos '' testuser
RUN chown -R testuser .
USER testuser

ENTRYPOINT [ "build/tests/docker-entrypoint.sh" ]

0 comments on commit e99a293

Please sign in to comment.