Skip to content

Commit

Permalink
fix image building (#312)
Browse files Browse the repository at this point in the history
  • Loading branch information
halamix2 authored Oct 23, 2024
1 parent e4c8bd9 commit 58a5557
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions docker/admission/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ FROM golang:1.21.5 as builder
ARG TARGETOS
ARG TARGETARCH

WORKDIR /workspace
WORKDIR /app
# Copy the Go Modules manifests
COPY go.mod go.mod
COPY go.sum go.sum
Expand All @@ -28,7 +28,7 @@ RUN CGO_ENABLED=0 GOOS=${TARGETOS:-linux} GOARCH=${TARGETARCH} go build -a -o ad
# Refer to https://github.com/GoogleContainerTools/distroless for more details
FROM gcr.io/distroless/static:nonroot
WORKDIR /
COPY --from=builder /workspace/admission .
COPY --from=builder /app/admission .
USER 65532:65532

ENTRYPOINT ["/admission"]
4 changes: 2 additions & 2 deletions docker/operator/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ FROM golang:1.21.5 as builder
ARG TARGETOS
ARG TARGETARCH

WORKDIR /workspace
WORKDIR /app
# Copy the Go Modules manifests
COPY go.mod go.mod
COPY go.sum go.sum
Expand All @@ -28,7 +28,7 @@ RUN CGO_ENABLED=0 GOOS=${TARGETOS:-linux} GOARCH=${TARGETARCH} go build -a -o op
# Refer to https://github.com/GoogleContainerTools/distroless for more details
FROM gcr.io/distroless/static:nonroot
WORKDIR /
COPY --from=builder /workspace/operator .
COPY --from=builder /app/operator .
USER 65532:65532

ENTRYPOINT ["/operator"]

0 comments on commit 58a5557

Please sign in to comment.