Skip to content

Commit

Permalink
CORS-3418: images: move installer images to static builds
Browse files Browse the repository at this point in the history
The baremetal-installer image continues being dynamically built for FIPS
support. For that reason it cannot reuse the existing
`terraform-providers` image. All other images will be statically built.
  • Loading branch information
r4f4 committed Mar 28, 2024
1 parent 6372dde commit c35dc12
Show file tree
Hide file tree
Showing 8 changed files with 20 additions and 3 deletions.
3 changes: 0 additions & 3 deletions images/baremetal/Dockerfile.ci
Original file line number Diff line number Diff line change
@@ -1,13 +1,10 @@
# This Dockerfile is a used by CI to publish an installer image
# It builds an image containing openshift-install.

FROM registry.ci.openshift.org/ocp/4.16:installer-terraform-providers AS providers

FROM registry.ci.openshift.org/ocp/builder:rhel-8-golang-1.21-openshift-4.16 AS builder
ARG TAGS="libvirt baremetal"
WORKDIR /go/src/github.com/openshift/installer
COPY . .
COPY --from=providers /go/src/github.com/openshift/installer/terraform/bin/ terraform/bin/
RUN DEFAULT_ARCH="$(go env GOHOSTARCH)" hack/build.sh


Expand Down
3 changes: 3 additions & 0 deletions images/infrastructure-providers/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# FIPS support is offered via the baremetal-installer image
ENV GO_COMPLIANCE_EXCLUDE=".*"

FROM registry.ci.openshift.org/ocp/builder:rhel-8-golang-1.21-openshift-4.16 AS macbuilder
WORKDIR /go/src/github.com/openshift/installer
COPY . .
Expand Down
2 changes: 2 additions & 0 deletions images/installer-altinfra/Dockerfile.ci
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@
# not be needed.

FROM registry.ci.openshift.org/ocp/builder:rhel-8-golang-1.21-openshift-4.16 AS builder
# FIPS support is offered via the baremetal-installer image
ENV GO_COMPLIANCE_EXCLUDE=".*"
ARG TAGS="altinfra"
ARG OPENSHIFT_INSTALL_CLUSTER_API=""
WORKDIR /go/src/github.com/openshift/installer
Expand Down
3 changes: 3 additions & 0 deletions images/installer-artifacts/Dockerfile.rhel
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@

FROM registry.ci.openshift.org/ocp/4.16:installer-terraform-providers AS providers

# FIPS support is offered via the baremetal-installer image
ENV GO_COMPLIANCE_EXCLUDE=".*"

FROM registry.ci.openshift.org/ocp/builder:rhel-8-golang-1.21-openshift-4.16 AS macbuilder
ARG TAGS=""
WORKDIR /go/src/github.com/openshift/installer
Expand Down
3 changes: 3 additions & 0 deletions images/installer/Dockerfile.ci
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@

FROM registry.ci.openshift.org/ocp/4.16:installer-terraform-providers AS providers

# FIPS support is offered via the baremetal-installer image
ENV GO_COMPLIANCE_EXCLUDE=".*"

FROM registry.ci.openshift.org/ocp/builder:rhel-8-golang-1.21-openshift-4.16 AS builder
ARG TAGS=""
WORKDIR /go/src/github.com/openshift/installer
Expand Down
3 changes: 3 additions & 0 deletions images/installer/Dockerfile.upi.ci
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@

FROM registry.ci.openshift.org/ocp/4.16:installer-terraform-providers as providers

# FIPS support is offered via the baremetal-installer image
ENV GO_COMPLIANCE_EXCLUDE=".*"

FROM registry.ci.openshift.org/ocp/builder:rhel-8-golang-1.21-openshift-4.16 AS builder
ARG TAGS=""
WORKDIR /go/src/github.com/openshift/installer
Expand Down
3 changes: 3 additions & 0 deletions images/libvirt/Dockerfile.ci
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@

FROM registry.ci.openshift.org/ocp/4.16:installer-terraform-providers as providers

# FIPS support is offered via the baremetal-installer image
ENV GO_COMPLIANCE_EXCLUDE=".*"

FROM registry.ci.openshift.org/ocp/builder:rhel-8-golang-1.21-openshift-4.16 AS builder
ARG TAGS="libvirt"
WORKDIR /go/src/github.com/openshift/installer
Expand Down
3 changes: 3 additions & 0 deletions images/openstack/Dockerfile.ci
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
# It builds an image containing the openshift-install command as well as the openstack cli.
FROM registry.ci.openshift.org/ocp/4.16:installer-terraform-providers as providers

# FIPS support is offered via the baremetal-installer image
ENV GO_COMPLIANCE_EXCLUDE=".*"

FROM registry.ci.openshift.org/ocp/builder:rhel-8-golang-1.21-openshift-4.16 AS builder
ARG TAGS=""
WORKDIR /go/src/github.com/openshift/installer
Expand Down

0 comments on commit c35dc12

Please sign in to comment.