Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions images/installer-artifacts/Dockerfile.rhel
Original file line number Diff line number Diff line change
@@ -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
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd rather stick with /$GOARCH/GOOS/openshift-install, like openshift/console-operator#177. I see three major consumers of these images:

  • openshift-install itself, where using the Go names makes it easy for us to construct and spit out a download link for oc. That doesn't directly impact openshift-install, but I think we should use the same pattern for oc and openshift-install to minimize mental overhead.
  • The web console, which is free to provide whatever translation is sees fit when suggesting download locations (e.g. "mac" or "macOS" text linking to a darwin URL). This is the approach Terraform uses, with nifty logos, and I think that works pretty well.
  • External docs like https://cloud.openshift.com/clusters/install. It sounds like the plan is to keep these pointing into here or similar, but can't we drop some HTML in there to get something prettier than a raw Apache directory browser? Once the web-console folks have worked something up, it should be easy to create a form with relative links for the download binaries drop copies into each of those download directories as we publish them, right?

Copy link
Contributor Author

@smarterclayton smarterclayton Mar 31, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't want the structure of this in the� image because "darwin" is user hostile for the majority of our users (as is the arch). This is primarily intended for consumers, not for our build infra, so we should bias towards them.

We have a small chance of ever supporting alternative architectures for Windows or Mac. We have a slightly larger chance of supporting linux alt arches (arm / power) but those are going to be special flows.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking at 177 I don't think that's the structure a human should see, but more of a machine actor (and I'm not sure what machine actor would use that instead of the cli image).

Copy link
Contributor Author

@smarterclayton smarterclayton Mar 31, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

External docs like https://cloud.openshift.com/clusters/install. It sounds like the plan is to keep these pointing into here or similar, but can't we drop some HTML in there to get something prettier than a raw Apache directory browser?

The plan is that that directory is going to be created by running oc adm release extract ... which creates a directory per release, and uses windows, linux, mac. Right now the discussed structure was:

root/
  latest-openshift-client-mac.tar.gz -> symlink to 4.0.5/openshift-install-mac-4.0.5.tar.gz
  latest -> symlink to a dir like 4.0.5/
  4.0.6/
    README.md
    LICENSE
    openshift-install-linux-4.0.6.tar.gz
    openshift-install-mac-4.0.6.tar.gz
    openshift-client-linux-4.0.6.tar.gz
    openshift-client-mac-4.0.6.tar.gz
    openshift-client-windows-4.0.6.zip
  4.0.5/
    ...
  4.0.4/
    ...

Copy link
Contributor Author

@smarterclayton smarterclayton Apr 1, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

After thinking about this a bit more, if we can make the argument that the location in the image will never be viewed by non-developers, I could buy /usr/share/openshift/GOOS/GOARCH/BINARY_NAME. But only if we don't expect anyone outside our team to ever see that directory.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

But only if we don't expect anyone outside our team to ever see that directory.

Yeah, I think "drop an index.html in there (possibly instead of the README.md?) so nobody has to look at the names (and possible subdir structure) ;).