Skip to content

Commit

Permalink
Fix arg usage for downstream builds (#558)
Browse files Browse the repository at this point in the history
  • Loading branch information
OlivierCazade committed Feb 12, 2025
1 parent 8e3e21d commit af89676
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions Dockerfile.downstream
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ ARG COMMIT
FROM --platform=linux/$TARGETARCH brew.registry.redhat.io/rh-osbs/openshift-golang-builder:v1.23 as builder

ARG TARGETARCH=amd64
ARG VERSION="unknown"
ARG BUILDVERSION="1.8.0"
ARG COMMIT

WORKDIR /opt/app-root
Expand All @@ -19,7 +19,7 @@ COPY go.mod go.mod
COPY go.sum go.sum

# Build
RUN GOARCH=$TARGETARCH go build -ldflags "-X 'main.buildVersion=${VERSION}-${COMMIT}' -X 'main.buildDate=`date +%Y-%m-%d\ %H:%M`'" -mod vendor -a -o bin/netobserv-ebpf-agent cmd/netobserv-ebpf-agent.go
RUN GOARCH=$TARGETARCH go build -ldflags "-X 'main.buildVersion=${BUILDVERSION}' -X 'main.buildDate=`date +%Y-%m-%d\ %H:%M`'" -mod vendor -a -o bin/netobserv-ebpf-agent cmd/netobserv-ebpf-agent.go

# Create final image from minimal + built binary
FROM --platform=linux/$TARGETARCH registry.access.redhat.com/ubi9/ubi-minimal:9.5-1738816775
Expand All @@ -38,7 +38,7 @@ LABEL io.k8s.description="Network Observability eBPF Agent"
LABEL summary="Network Observability eBPF Agent"
LABEL maintainer="[email protected]"
LABEL io.openshift.tags="network-observability-ebpf-agent"
LABEL upstream-vcs-ref="$COMMIT"
LABEL upstream-vcs-ref=$COMMIT
LABEL upstream-vcs-type="git"
LABEL description="The Network Observability eBPF Agent allows collecting and aggregating all the ingress and egress flows on a Linux host."
LABEL version="1.8.0"
LABEL version=$BUILDVERSION

0 comments on commit af89676

Please sign in to comment.