-
Notifications
You must be signed in to change notification settings - Fork 20
Start adding 03_create_cluster.sh. #35
Conversation
This is the beginning of a create_cluster script. It knows how to extract the baremetal installer from an OpenShift release image and run it. There are still some missing pieces, most notably some help in generating a complete install-config.yaml with the details of the bare metal hosts. Known todo items are listed with links to their corresponding issues.
|
/lgtm |
markmc
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(bah, forgot to submit these)
| source logging.sh | ||
| source common.sh | ||
|
|
||
| export OPENSHIFT_INSTALL_RELEASE_IMAGE_OVERRIDE="${OPENSHIFT_INSTALL_RELEASE_IMAGE_OVERRIDE:-registry.svc.ci.openshift.org/ocp/release:4.2}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When openshift/oc#57 merges, we'll no longer set OPENSHIFT_INSTALL_RELEASE_IMAGE_OVERRIDE so you could do e.g.
export OPENSHIFT_RELEASE_IMAGE=...
extract_installer $OPENSHIFT_RELEASE_IMAGE ...
# FIXME: remove OPENSHIFT_INSTALL_RELASE_IMAGE_OVERRIDE when openshift/oc#57 merges
OPENSHIFT_INSTALL_RELEASE_IMAGE_OVERRIDE=$OPENSHIFT_RELEASE_IMAGE ${OPENSHIFT_INSTALLER} ...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, I just copied the current version of what's done in dev-scripts
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This pattern indeed looks nicer 👍
| cp install-config.yaml ocp/ | ||
| ${OPENSHIFT_INSTALLER} --dir ocp create manifests | ||
| # TODO - Add custom install time manifests here: | ||
| # - https://github.com/openshift-kni/install-scripts/issues/30 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See my comment in #30 - I'm unclear whether using create manifests is a temporary workaround or something we have to live with while we're using OpenShift 4.2
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's something we have to live with during 4.2, because a couple of things (most notably the ConfigMap required to start the BMO/Ironic containers via the MAO, and the BaremetalHost CRD) need to be added which aren't currently integrated into the installer.
We expect that integration work to be completed in the 4.3 timeframe, but for now I think we've got no option than to inject these pieces via manifests.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Russell suggested re-looking at the BMO config map issue - #30 (comment)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I can drop it from this script for now while we sort it out. The install won't work successfully without it though. The machine-api-operator will fail to come up, because the metal3 deployment it manages will be busted without its config.
|
Ok, let's merge and iterate |
This is based on feedback from openshift-kni#35. The release override can be dropped once the oc changes merge that allow us to extract the installer with the release image set appropriately. Move the release override var to one spot where it'll easily be removed when the time comes. Also drop "create manifests", as we don't use it yet, and it's unclear if we'll keep it at all.
This is the beginning of a create_cluster script. It knows how to
extract the baremetal installer from an OpenShift release image and
run it.
There are still some missing pieces, most notably some help in
generating a complete install-config.yaml with the details of the bare
metal hosts. Known todo items are listed with links to their
corresponding issues.