File tree Expand file tree Collapse file tree 2 files changed +14
-8
lines changed
Expand file tree Collapse file tree 2 files changed +14
-8
lines changed Original file line number Diff line number Diff line change @@ -422,7 +422,7 @@ $(node_map_to_install_config_hosts $NUM_MASTERS 0 master)
422422EOF
423423 fi
424424
425- if ! is_lower_version " $( openshift_version $OCP_DIR ) " " 4.21 " ; then
425+ if ! is_lower_version " $( openshift_version $OCP_DIR ) " " 4.22 " ; then
426426 cat >> " ${outdir} /install-config.yaml" << EOF
427427 bmcVerifyCA: |
428428$( sudo sed ' s/^/ /' " ${WORKING_DIR} /virtualbmc/sushy-tools/cert.pem" )
@@ -472,8 +472,12 @@ function generate_ocp_host_manifest() {
472472
473473 encoded_username=$( echo -n " $username " | base64)
474474 encoded_password=$( echo -n " $password " | base64)
475- # Heads up, "verify_ca" in ironic driver config, and "disableCertificateVerification" in BMH have opposite meaning
476- disableCertificateVerification=$( [ " $verify_ca " = " False" ] && echo " true" || echo " false" )
475+ if is_lower_version " $( openshift_version $OCP_DIR ) " " 4.22" ; then
476+ # Heads up, "verify_ca" in ironic driver config, and "disableCertificateVerification" in BMH have opposite meaning
477+ disableCertificateVerification=$( [ " $verify_ca " = " False" ] && echo " true" || echo " false" )
478+ else
479+ disableCertificateVerification=false
480+ fi
477481
478482 secret=" ---
479483apiVersion: v1
Original file line number Diff line number Diff line change @@ -268,13 +268,15 @@ function node_map_to_install_config_hosts() {
268268EOF
269269
270270 if [[ " $driver_prefix " == " redfish" ]]; then
271- # Set disableCertificateVerification
272- # Heads up, "verify ca" in ironic driver config, and "disableCertificateVerification" in BMH have opposite meaning
273- verify_ca=$( node_val ${idx} " driver_info.redfish_verify_ca" )
274- disable_certificate_verification=$( [ " $verify_ca " = " False" ] && echo " true" || echo " false" )
275- cat << EOF
271+ # Set disableCertificateVerification on older versions
272+ if is_lower_version " $( openshift_version $OCP_DIR ) " " 4.22" ; then
273+ # Heads up, "verify ca" in ironic driver config, and "disableCertificateVerification" in BMH have opposite meaning
274+ verify_ca=$( node_val ${idx} " driver_info.redfish_verify_ca" )
275+ disable_certificate_verification=$( [ " $verify_ca " = " False" ] && echo " true" || echo " false" )
276+ cat << EOF
276277 disableCertificateVerification: ${disable_certificate_verification}
277278EOF
279+ fi
278280 fi
279281
280282
You can’t perform that action at this time.
0 commit comments