forked from k8snetworkplumbingwg/whereabouts
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This commit alters the Dockerfile for both regular and OpenShift in such a way multiarch images are getting built when using buildkit. Also, the GH workflow actually building the images is prepared for that. Fixes k8snetworkplumbingwg#226 Signed-off-by: Jorik Jonker <jorik.jonker@eu.equinix.com>
- Loading branch information
Showing
7 changed files
with
26 additions
and
114 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,14 @@ | ||
FROM golang:1.19 | ||
FROM --platform=$BUILDPLATFORM golang:1.19 as builder | ||
ADD . /usr/src/whereabouts | ||
RUN mkdir -p $GOPATH/src/github.com/k8snetworkplumbingwg/whereabouts | ||
WORKDIR $GOPATH/src/github.com/k8snetworkplumbingwg/whereabouts | ||
COPY . . | ||
RUN ./hack/build-go.sh | ||
ARG TARGETOS TARGETARCH | ||
RUN GOOS=$TARGETOS GOARCH=$TARGETARCH ./hack/build-go.sh | ||
|
||
FROM alpine:latest | ||
LABEL org.opencontainers.image.source https://github.com/k8snetworkplumbingwg/whereabouts | ||
COPY --from=0 /go/src/github.com/k8snetworkplumbingwg/whereabouts/bin/whereabouts . | ||
COPY --from=0 /go/src/github.com/k8snetworkplumbingwg/whereabouts/bin/ip-control-loop . | ||
COPY --from=builder /go/src/github.com/k8snetworkplumbingwg/whereabouts/bin/whereabouts . | ||
COPY --from=builder /go/src/github.com/k8snetworkplumbingwg/whereabouts/bin/ip-control-loop . | ||
COPY script/install-cni.sh . | ||
CMD ["/install-cni.sh"] |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters