diff --git a/Dockerfile b/Dockerfile index 0b3bf8b..f56b536 100644 --- a/Dockerfile +++ b/Dockerfile @@ -2,7 +2,7 @@ FROM --platform=$BUILDPLATFORM golang:latest COPY . /go/src/github.com/chmouel/gosmee WORKDIR /go/src/github.com/chmouel/gosmee ARG TARGETARCH -RUN CGO_ENABLED=0 GOOS=linux GOARCH=${TARGETARCH} go build -a -ldflags="-s -w" -installsuffix cgo -o /tmp/gosmee . +RUN GOFLAGS="-buildvcs=false" CGO_ENABLED=0 GOOS=linux GOARCH=${TARGETARCH} go build -a -ldflags="-s -w" -installsuffix cgo -o /tmp/gosmee . FROM registry.access.redhat.com/ubi9/ubi-minimal RUN microdnf -y update && microdnf -y --nodocs install tar rsync shadow-utils && microdnf clean all && useradd gosmee && rm -rf /var/cache/yum