File tree Expand file tree Collapse file tree 1 file changed +2
-7
lines changed Expand file tree Collapse file tree 1 file changed +2
-7
lines changed Original file line number Diff line number Diff line change @@ -3,6 +3,8 @@ FROM registry.access.redhat.com/ubi9/go-toolset:1.23 AS builder
33
44ARG TARGETOS TARGETARCH
55
6+ USER root
7+
68# Install system dependencies
79RUN dnf upgrade -y && dnf install -y \
810 gcc \
@@ -11,12 +13,6 @@ RUN dnf upgrade -y && dnf install -y \
1113 git \
1214 && dnf clean all && rm -rf /var/cache/yum
1315
14- # Install Go
15- ENV PATH=/usr/local/go/bin:$PATH
16-
17- COPY --from=golang /usr/local/go /usr/local/go
18- # End of Go versioning workaround
19-
2016WORKDIR /workspace
2117# Copy the Go Modules manifests
2218COPY go.mod go.mod
@@ -29,7 +25,6 @@ COPY main.go main.go
2925COPY pkg/ pkg/
3026
3127# Build
32- USER root
3328RUN CGO_ENABLED=1 GOOS=${TARGETOS:-linux} GOARCH=${TARGETARCH:-amd64} make go-build-for-image
3429
3530FROM registry.access.redhat.com/ubi8/ubi-minimal:8.8
You can’t perform that action at this time.
0 commit comments