File tree Expand file tree Collapse file tree 1 file changed +6
-4
lines changed
Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -51,13 +51,15 @@ named_resources+=(${MEDIK8S_CRDS})
5151MEDIK8S_CRS=$( oc get crds -o jsonpath=' {range .items[*]}{.metadata.name}{"\n"}{end}' | grep ' medik8s' | sed -z ' s/\n/ /g' )
5252group_resources+=(${MEDIK8S_CRS} )
5353
54- # Metal3
55- group_resources+=(metal3remediationtemplates)
56- group_resources+=(metal3remediations)
57-
5854# Run the Collection of Resources using inspect
5955oc adm inspect --dest-dir must-gather --rotated-pod-logs --all-namespaces " ${named_resources[@]} "
6056group_resources_text=$( IFS=, ; echo " ${group_resources[*]} " )
6157oc adm inspect --dest-dir must-gather --rotated-pod-logs --all-namespaces " ${group_resources_text} "
6258
59+ # Handle metal3 separately as they don't exist in OCP 4.12 and below, and they would fail gathering all other resources
60+ group_resources=(metal3remediationtemplates)
61+ group_resources+=(metal3remediations)
62+ group_resources_text=$( IFS=, ; echo " ${group_resources[*]} " )
63+ oc adm inspect --dest-dir must-gather --rotated-pod-logs --all-namespaces " ${group_resources_text} "
64+
6365exit 0
You can’t perform that action at this time.
0 commit comments