From 3a626cd7cf489d60b53881f1f024e4a7df3cf8f1 Mon Sep 17 00:00:00 2001 From: Clayton Coleman Date: Sun, 31 Mar 2019 13:37:50 -0400 Subject: [PATCH] image: Add a production "installer-artifacts" image for Mac binary To ensure the payload is reproducible, we will include images for both cli and installer commands for non linux platforms that allow users to get the correct tools to install the release image. Since the installer binary is not small and we don't want to take the cost to pull it on each node when in use from hive, create a new image installer-artifacts that layers on top of installer (inheriting the default installer Linux binary) and places the darwin binary into /usr/share/openshift/mac/openshift-install. This directory structure is kept deliberately simple for end users - if we do in the future need to deal with multi-arch concerns we'll do that at a higher level and in practice neither 32bit nor arm will be "supported" as part of the core distro yet. The dockerfile matches the desired final form from the release team (Dockerfile.rhel) and will be used in both CI and publishing. --- images/installer-artifacts/Dockerfile.rhel | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 images/installer-artifacts/Dockerfile.rhel diff --git a/images/installer-artifacts/Dockerfile.rhel b/images/installer-artifacts/Dockerfile.rhel new file mode 100644 index 00000000000..f86f81c015e --- /dev/null +++ b/images/installer-artifacts/Dockerfile.rhel @@ -0,0 +1,10 @@ +# This Dockerfile builds an image containing the Mac version of the installer layered +# on top of the Linux installer image. + +FROM registry.svc.ci.openshift.org/ocp/builder:golang-1.10 AS builder +WORKDIR /go/src/github.com/openshift/installer +COPY . . +RUN SKIP_GENERATION=y GOOS=darwin GOARCH=amd64 hack/build.sh + +FROM registry.svc.ci.openshift.org/ocp/4.0:installer +COPY --from=builder /go/src/github.com/openshift/installer/bin/openshift-install /usr/share/openshift/mac/openshift-install