Skip to content
Merged
Show file tree
Hide file tree
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
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,8 @@ function cvoCapabilityCheck() {
else
echo "ERROR: ${expected_status} capabilities does not match with cvo ${cvo_field}!"
echo -e "cvo_caps: ${cvo_caps_str}\n${expected_status} capability set: ${capability_set}"
echo "diff [cvo_caps] [${expected_status} capability set]"
diff <( echo $cvo_caps_str | tr " " "\n" | sort | uniq) <( echo $capability_set | tr " " "\n" | sort | uniq )
result=1
fi
fi
Expand Down Expand Up @@ -84,6 +86,7 @@ caps_operator[Storage]="storage"
caps_operator[NodeTuning]="node-tuning"
caps_operator[MachineAPI]="machine-api control-plane-machine-set cluster-autoscaler"
caps_operator[ImageRegistry]="image-registry"
caps_operator[OperatorLifecycleManager]="operator-lifecycle-manager operator-lifecycle-manager-catalog operator-lifecycle-manager-packageserver"

# Mapping between optional capability and resources
# Need to be updated when new resource marks as optional
Expand All @@ -97,7 +100,8 @@ v411="baremetal marketplace openshift-samples"
v412=" ${v411} Console Insights Storage CSISnapshot"
v413=" ${v412} NodeTuning"
v414=" ${v413} MachineAPI Build DeploymentConfig ImageRegistry"
latest_defined="v414"
v415=" ${v414} OperatorLifecycleManager"
latest_defined="v415"
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

can you help also update ipi-conf-capability-additonalcaps together?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Updated.

always_default="${!latest_defined}"

# Determine vCurrent
Expand Down Expand Up @@ -132,6 +136,9 @@ case ${baselinecaps_from_config} in
"v4.14")
enabled_capability_set="${v414}"
;;
"v4.15")
enabled_capability_set="${v415}"
;;
"vCurrent")
enabled_capability_set="${vCurrent}"
;;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,9 @@ v412=" ${v411} Console Insights Storage CSISnapshot"
v413=" ${v412} NodeTuning"
# shellcheck disable=SC2034
v414=" ${v413} MachineAPI Build DeploymentConfig ImageRegistry"
latest_version="v414"
# shellcheck disable=SC2034
v415=" ${v414} OperatorLifecycleManager"
latest_version="v415"

declare "v${ocp_major_version}${ocp_minor_version}"
v_current_version="v${ocp_major_version}${ocp_minor_version}"
Expand Down Expand Up @@ -96,6 +98,12 @@ if [[ "${selected_capability}" == "ImageRegistry" ]]; then
enabled_capabilities=${enabled_capabilities/"Build"}
fi

# Disable marketplace if OperatorLifecycleManager is selected to bo disabled
if [[ "${selected_capability}" == "OperatorLifecycleManager" ]]; then
echo "Capability 'marketplace' depends on Capability 'OperatorLifecycleManager', so disable marketplace along with OperatorLifecycleManager"
enabled_capabilities=${enabled_capabilities/"marketplace"}
fi

# apply patch to install-config
CONFIG="${SHARED_DIR}/install-config.yaml"
PATCH="/tmp/install-config-capability.yaml.path"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,9 +50,10 @@ ocp_minor_version=$( echo "${ocp_version}" | awk --field-separator=. '{print $2}
v411_set="vCurrent v4.11"
v412_set="${v411_set} v4.12"
v413_set="${v412_set} v4.13"
# shellcheck disable=SC2034
v414_set="${v413_set} v4.14"
latest_version_set="v414_set"
# shellcheck disable=SC2034
v415_set="${v414_set} v4.15"
latest_version_set="v415_set"

declare "v${ocp_major_version}${ocp_minor_version}_set"
v_current_version="v${ocp_major_version}${ocp_minor_version}_set"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,8 @@ v411="baremetal marketplace openshift-samples"
v412=" ${v411} Console Insights Storage CSISnapshot"
v413=" ${v412} NodeTuning"
v414=" ${v413} MachineAPI Build DeploymentConfig ImageRegistry"
latest_defined="v414"
v415=" ${v414} OperatorLifecycleManager"
latest_defined="v415"
always_default="${!latest_defined}"

# Determine vCurrent
Expand Down Expand Up @@ -93,6 +94,9 @@ case ${BASELINE_CAPABILITY_SET} in
"v4.14")
enabled_operators="${v414}"
;;
"v4.15")
enabled_operators="${v415}"
;;
"vCurrent")
enabled_operators="${vCurrent}"
;;
Expand Down