Skip to content

Commit

Permalink
ovirt: fix ovirt-populator build
Browse files Browse the repository at this point in the history
Fix oVirt populator build when done in a git workspace

Resolves #411

Signed-off-by: Miguel Martín <mmartinv@redhat.com>
  • Loading branch information
mmartinv authored and ahadas committed Jun 27, 2023
1 parent 3cd3876 commit 3dba136
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions hack/ovirt-populator/Containerfile
Original file line number Diff line number Diff line change
@@ -1,10 +1,14 @@
FROM registry.access.redhat.com/ubi8/go-toolset:1.18.9-8 as builder
ENV GOPATH=$APP_ROOT
COPY . .

COPY go.mod ./
COPY go.sum ./
COPY cmd/ovirt-populator/ovirt-populator.go ./
COPY vendor/ ./vendor/
# When debugging by replacing the lib-volume-populator with a local modified copy
# COPY . ./
RUN CGO_ENABLED=0 go build -o ovirt-populator github.com/konveyor/forklift-controller/cmd/ovirt-populator

RUN CGO_ENABLED=0 go build -o ovirt-populator

FROM quay.io/centos/centos:stream9-minimal
COPY --from=builder /opt/app-root/src/ovirt-populator /usr/local/bin
Expand Down

0 comments on commit 3dba136

Please sign in to comment.