Skip to content

Commit

Permalink
Merge pull request #210 from bookingcom/emadolsky/use-nonroot-user-in…
Browse files Browse the repository at this point in the history
…-dockerfiles

Use nonroot user in dockerfiles
  • Loading branch information
emadolsky committed Dec 15, 2023
2 parents dc9b169 + cad71ed commit ec279c9
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
3 changes: 3 additions & 0 deletions test/k8s/nt.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@ WORKDIR /nt
COPY --from=builder /nt/nanotube /nt
COPY ./k8s/config /nt/config

RUN adduser graphite --disabled-password
USER graphite

# main listening port
EXPOSE 2003
# Prometheus port
Expand Down
3 changes: 3 additions & 0 deletions test/k8s/sender.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,7 @@ WORKDIR /nt
COPY --from=builder /nt/sender /nt
COPY --from=builder /nt/k8s/in /nt/in

RUN adduser graphite --disabled-password
USER graphite

ENTRYPOINT ["./sender", "-data", "in", "-host", "localhost", "-port", "2003", "-rate", "100", "-cycle", "-retryTCP", "-promPort", "9090"]

0 comments on commit ec279c9

Please sign in to comment.