Skip to content

Commit

Permalink
test distroless image
Browse files Browse the repository at this point in the history
  • Loading branch information
Rosyya committed Aug 14, 2024
1 parent feb20c6 commit f55089c
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions Dockerfile.distroless
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,13 @@ RUN apk add --no-cache gcc libstdc++-dev libc-dev
RUN cd /gnfd-qa-test-monitor \
&& go build -o ./build/monitor main.go

RUN pwd && ls -al
RUN cd /gnfd-qa-test-monitor && pwd && ls -al

FROM alpine:3.17

USER nonroot:nonroot
WORKDIR /home/nonroot
COPY --from=builder --chown=nonroot:nonroot /gnfd-qa-test-monitor/build/monitor $WORKDIR
RUN pwd && ls -al
# COPY --from=builder --chown=nonroot:nonroot /gnfd-qa-test-monitor/build/monitor $WORKDIR
COPY --from=builder /gnfd-qa-test-monitor/build/monitor $WORKDIR
RUN cd /gnfd-qa-test-monitor && pwd && ls -al
ENTRYPOINT ["./monitor"]

0 comments on commit f55089c

Please sign in to comment.