@openshift-assisted/ui-lib 2.38.2 → 2.38.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/@types/cim/components/ClusterDeployment/wizardTransition.d.ts +1 -1
- package/build/@types/cim/components/ClusterDeployment/wizardTransition.d.ts.map +1 -1
- package/build/@types/common/config/constants.d.ts +8 -0
- package/build/@types/common/config/constants.d.ts.map +1 -1
- package/build/@types/common/config/docs_links.d.ts.map +1 -1
- package/build/@types/common/types/clusters.d.ts +2 -0
- package/build/@types/common/types/clusters.d.ts.map +1 -1
- package/build/@types/ocm/components/clusterConfiguration/operators/AmdGpuCheckbox.d.ts +8 -0
- package/build/@types/ocm/components/clusterConfiguration/operators/AmdGpuCheckbox.d.ts.map +1 -0
- package/build/@types/ocm/components/clusterConfiguration/operators/KmmCheckbox.d.ts +6 -0
- package/build/@types/ocm/components/clusterConfiguration/operators/KmmCheckbox.d.ts.map +1 -0
- package/build/@types/ocm/components/clusterConfiguration/operators/MtvOperatorCheckbox.d.ts.map +1 -1
- package/build/@types/ocm/components/clusterConfiguration/operators/OpenshiftAIAmdRequirements.d.ts +4 -0
- package/build/@types/ocm/components/clusterConfiguration/operators/OpenshiftAIAmdRequirements.d.ts.map +1 -0
- package/build/@types/ocm/components/clusterConfiguration/operators/OpenshiftAINvidiaRequirements.d.ts.map +1 -1
- package/build/@types/ocm/components/clusterConfiguration/operators/SupportedOperators.d.ts.map +1 -1
- package/build/@types/ocm/components/clusterWizard/Operators.d.ts.map +1 -1
- package/build/@types/ocm/components/clusterWizard/OperatorsStep.d.ts.map +1 -1
- package/build/@types/ocm/components/clusterWizard/wizardTransition.d.ts +1 -1
- package/build/@types/ocm/components/clusterWizard/wizardTransition.d.ts.map +1 -1
- package/build/@types/ocm/components/featureSupportLevels/featureStateUtils.d.ts.map +1 -1
- package/build/@types/ocm/services/OperatorsService.d.ts.map +1 -1
- package/build/cjs/common/config/constants.js +13 -1
- package/build/cjs/common/config/constants.js.map +1 -1
- package/build/cjs/common/config/docs_links.js +8 -1
- package/build/cjs/common/config/docs_links.js.map +1 -1
- package/build/cjs/common/types/clusters.js.map +1 -1
- package/build/cjs/ocm/components/clusterConfiguration/operators/AmdGpuCheckbox.js +29 -0
- package/build/cjs/ocm/components/clusterConfiguration/operators/AmdGpuCheckbox.js.map +1 -0
- package/build/cjs/ocm/components/clusterConfiguration/operators/KmmCheckbox.js +34 -0
- package/build/cjs/ocm/components/clusterConfiguration/operators/KmmCheckbox.js.map +1 -0
- package/build/cjs/ocm/components/clusterConfiguration/operators/MtvOperatorCheckbox.js +2 -0
- package/build/cjs/ocm/components/clusterConfiguration/operators/MtvOperatorCheckbox.js.map +1 -1
- package/build/cjs/ocm/components/clusterConfiguration/operators/NvidiaGpuCheckbox.js +1 -1
- package/build/cjs/ocm/components/clusterConfiguration/operators/NvidiaGpuCheckbox.js.map +1 -1
- package/build/cjs/ocm/components/clusterConfiguration/operators/OpenshiftAIAmdRequirements.js +32 -0
- package/build/cjs/ocm/components/clusterConfiguration/operators/OpenshiftAIAmdRequirements.js.map +1 -0
- package/build/cjs/ocm/components/clusterConfiguration/operators/OpenshiftAINvidiaRequirements.js +2 -1
- package/build/cjs/ocm/components/clusterConfiguration/operators/OpenshiftAINvidiaRequirements.js.map +1 -1
- package/build/cjs/ocm/components/clusterConfiguration/operators/SupportedOperators.js +8 -0
- package/build/cjs/ocm/components/clusterConfiguration/operators/SupportedOperators.js.map +1 -1
- package/build/cjs/ocm/components/clusterWizard/Operators.js +2 -0
- package/build/cjs/ocm/components/clusterWizard/Operators.js.map +1 -1
- package/build/cjs/ocm/components/clusterWizard/OperatorsStep.js +55 -30
- package/build/cjs/ocm/components/clusterWizard/OperatorsStep.js.map +1 -1
- package/build/cjs/ocm/components/clusterWizard/wizardTransition.js +2 -0
- package/build/cjs/ocm/components/clusterWizard/wizardTransition.js.map +1 -1
- package/build/cjs/ocm/components/featureSupportLevels/featureStateUtils.js +5 -0
- package/build/cjs/ocm/components/featureSupportLevels/featureStateUtils.js.map +1 -1
- package/build/cjs/ocm/services/OperatorsService.js +2 -0
- package/build/cjs/ocm/services/OperatorsService.js.map +1 -1
- package/lib/common/config/constants.ts +12 -0
- package/lib/common/config/docs_links.ts +7 -2
- package/lib/common/types/clusters.ts +2 -0
- package/lib/ocm/components/clusterConfiguration/operators/AmdGpuCheckbox.tsx +63 -0
- package/lib/ocm/components/clusterConfiguration/operators/KmmCheckbox.tsx +68 -0
- package/lib/ocm/components/clusterConfiguration/operators/MtvOperatorCheckbox.tsx +1 -0
- package/lib/ocm/components/clusterConfiguration/operators/NvidiaGpuCheckbox.tsx +1 -1
- package/lib/ocm/components/clusterConfiguration/operators/OpenshiftAIAmdRequirements.tsx +36 -0
- package/lib/ocm/components/clusterConfiguration/operators/OpenshiftAINvidiaRequirements.tsx +2 -1
- package/lib/ocm/components/clusterConfiguration/operators/SupportedOperators.tsx +10 -0
- package/lib/ocm/components/clusterWizard/Operators.tsx +4 -0
- package/lib/ocm/components/clusterWizard/OperatorsStep.tsx +68 -47
- package/lib/ocm/components/clusterWizard/_wizardTransition.test.ts +10 -0
- package/lib/ocm/components/clusterWizard/wizardTransition.ts +2 -0
- package/lib/ocm/components/featureSupportLevels/featureStateUtils.ts +5 -0
- package/lib/ocm/services/OperatorsService.tsx +4 -0
- package/package.json +3 -3
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
import React, { useState } from 'react';
|
|
2
|
+
import { FormGroup, HelperText, HelperTextItem, Tooltip } from '@patternfly/react-core';
|
|
3
|
+
import { getFieldId, PopoverIcon } from '../../../../common';
|
|
4
|
+
import { OcmCheckboxField } from '../../ui/OcmFormFields';
|
|
5
|
+
import { useNewFeatureSupportLevel } from '../../../../common/components/newFeatureSupportLevels';
|
|
6
|
+
import NewFeatureSupportLevelBadge from '../../../../common/components/newFeatureSupportLevels/NewFeatureSupportLevelBadge';
|
|
7
|
+
import { SupportLevel } from '@openshift-assisted/types/./assisted-installer-service';
|
|
8
|
+
|
|
9
|
+
const KMM_FIELD_NAME = 'useKmm';
|
|
10
|
+
|
|
11
|
+
const KmmLabel = ({
|
|
12
|
+
disabledReason,
|
|
13
|
+
supportLevel,
|
|
14
|
+
}: {
|
|
15
|
+
disabledReason?: string;
|
|
16
|
+
supportLevel?: SupportLevel;
|
|
17
|
+
}) => {
|
|
18
|
+
return (
|
|
19
|
+
<>
|
|
20
|
+
<Tooltip hidden={!disabledReason} content={disabledReason}>
|
|
21
|
+
<span>Install Kernel Module Management </span>
|
|
22
|
+
</Tooltip>
|
|
23
|
+
<PopoverIcon
|
|
24
|
+
id={KMM_FIELD_NAME}
|
|
25
|
+
component={'a'}
|
|
26
|
+
bodyContent={'No additional requirements needed'}
|
|
27
|
+
/>
|
|
28
|
+
<NewFeatureSupportLevelBadge featureId="KMM" supportLevel={supportLevel} />
|
|
29
|
+
</>
|
|
30
|
+
);
|
|
31
|
+
};
|
|
32
|
+
|
|
33
|
+
const KmmHelperText = () => {
|
|
34
|
+
return (
|
|
35
|
+
<HelperText>
|
|
36
|
+
<HelperTextItem variant="indeterminate">Management of kernel modules. </HelperTextItem>
|
|
37
|
+
</HelperText>
|
|
38
|
+
);
|
|
39
|
+
};
|
|
40
|
+
|
|
41
|
+
const KmmCheckbox = ({ disabledReason }: { disabledReason?: string }) => {
|
|
42
|
+
const fieldId = getFieldId(KMM_FIELD_NAME, 'input');
|
|
43
|
+
const featureSupportLevel = useNewFeatureSupportLevel();
|
|
44
|
+
const [disabledReasonKmm, setDisabledReason] = useState<string | undefined>();
|
|
45
|
+
|
|
46
|
+
React.useEffect(() => {
|
|
47
|
+
const reason = featureSupportLevel.getFeatureDisabledReason('KMM');
|
|
48
|
+
setDisabledReason(reason);
|
|
49
|
+
}, [featureSupportLevel]);
|
|
50
|
+
|
|
51
|
+
return (
|
|
52
|
+
<FormGroup isInline fieldId={fieldId}>
|
|
53
|
+
<OcmCheckboxField
|
|
54
|
+
name={KMM_FIELD_NAME}
|
|
55
|
+
label={
|
|
56
|
+
<KmmLabel
|
|
57
|
+
disabledReason={disabledReason ? disabledReason : disabledReasonKmm}
|
|
58
|
+
supportLevel={featureSupportLevel.getFeatureSupportLevel('KMM')}
|
|
59
|
+
/>
|
|
60
|
+
}
|
|
61
|
+
helperText={<KmmHelperText />}
|
|
62
|
+
isDisabled={!!disabledReason || !!disabledReasonKmm}
|
|
63
|
+
/>
|
|
64
|
+
</FormGroup>
|
|
65
|
+
);
|
|
66
|
+
};
|
|
67
|
+
|
|
68
|
+
export default KmmCheckbox;
|
|
@@ -70,6 +70,7 @@ const MtvCheckbox = ({
|
|
|
70
70
|
const selectCNVOperator = (checked: boolean) => {
|
|
71
71
|
if (featureSupportLevelData.isFeatureSupported('CNV'))
|
|
72
72
|
setFieldValue('useContainerNativeVirtualization', checked);
|
|
73
|
+
if (featureSupportLevelData.isFeatureSupported('LSO')) setFieldValue('useLso', checked);
|
|
73
74
|
};
|
|
74
75
|
|
|
75
76
|
return (
|
|
@@ -23,7 +23,7 @@ const NvidiaGpuLabel = ({
|
|
|
23
23
|
<PopoverIcon
|
|
24
24
|
id={NVIDIAGPU_FIELD_NAME}
|
|
25
25
|
component={'a'}
|
|
26
|
-
bodyContent={'
|
|
26
|
+
bodyContent={'Requires at least one supported NVIDIA GPU'}
|
|
27
27
|
/>
|
|
28
28
|
<NewFeatureSupportLevelBadge featureId="NVIDIA_GPU" supportLevel={supportLevel} />
|
|
29
29
|
</>
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { List, ListItem } from '@patternfly/react-core';
|
|
3
|
+
import { ExternalLinkAltIcon } from '@patternfly/react-icons/dist/js/icons/external-link-alt-icon';
|
|
4
|
+
import { OPENSHIFT_AI_REQUIREMENTS_LINK } from '../../../../common';
|
|
5
|
+
|
|
6
|
+
const OpenshiftAIAmdRequirements = () => {
|
|
7
|
+
return (
|
|
8
|
+
<>
|
|
9
|
+
<List>
|
|
10
|
+
<ListItem>At least two worker nodes.</ListItem>
|
|
11
|
+
<ListItem>
|
|
12
|
+
Each worker node requires 32 additional GiB of memory and 8 additional CPUs.
|
|
13
|
+
</ListItem>
|
|
14
|
+
<ListItem>At least one supported AMD GPU.</ListItem>
|
|
15
|
+
<ListItem>Nodes that have AMD GPUs installed need to have secure boot disabled.</ListItem>
|
|
16
|
+
</List>
|
|
17
|
+
Bundle operators:
|
|
18
|
+
<List>
|
|
19
|
+
<ListItem>Openshift AI</ListItem>
|
|
20
|
+
<ListItem>OpenShift Data Foundation</ListItem>
|
|
21
|
+
<ListItem>AMD GPU</ListItem>
|
|
22
|
+
<ListItem>Node Feature Discovery</ListItem>
|
|
23
|
+
<ListItem>Kernel Module Management</ListItem>
|
|
24
|
+
<ListItem>Pipelines</ListItem>
|
|
25
|
+
<ListItem>Service Mesh</ListItem>
|
|
26
|
+
<ListItem>Serverless</ListItem>
|
|
27
|
+
<ListItem>Authorino</ListItem>
|
|
28
|
+
</List>
|
|
29
|
+
<a href={OPENSHIFT_AI_REQUIREMENTS_LINK} target="_blank" rel="noopener noreferrer">
|
|
30
|
+
Learn more <ExternalLinkAltIcon />.
|
|
31
|
+
</a>
|
|
32
|
+
</>
|
|
33
|
+
);
|
|
34
|
+
};
|
|
35
|
+
|
|
36
|
+
export default OpenshiftAIAmdRequirements;
|
|
@@ -11,7 +11,7 @@ const OpenshiftAINvidiaRequirements = () => {
|
|
|
11
11
|
<ListItem>
|
|
12
12
|
Each worker node requires 32 additional GiB of memory and 8 additional CPUs.
|
|
13
13
|
</ListItem>
|
|
14
|
-
<ListItem>At least one supported
|
|
14
|
+
<ListItem>At least one supported NVIDIA GPU.</ListItem>
|
|
15
15
|
<ListItem>
|
|
16
16
|
Nodes that have NVIDIA GPUs installed need to have secure boot disabled.
|
|
17
17
|
</ListItem>
|
|
@@ -21,6 +21,7 @@ const OpenshiftAINvidiaRequirements = () => {
|
|
|
21
21
|
<ListItem>Openshift AI</ListItem>
|
|
22
22
|
<ListItem>OpenShift Data Foundation</ListItem>
|
|
23
23
|
<ListItem>NVIDIA GPU</ListItem>
|
|
24
|
+
<ListItem>Node Feature Discovery</ListItem>
|
|
24
25
|
<ListItem>Pipelines</ListItem>
|
|
25
26
|
<ListItem>Service Mesh</ListItem>
|
|
26
27
|
<ListItem>Serverless</ListItem>
|
|
@@ -14,10 +14,14 @@ import AuthorinoCheckbox from './AuthorinoCheckbox';
|
|
|
14
14
|
import PipelinesCheckbox from './PipelinesChekbox';
|
|
15
15
|
import ServiceMeshCheckbox from './ServicemeshCheckbox';
|
|
16
16
|
import NvidiaGpuCheckbox from './NvidiaGpuCheckbox';
|
|
17
|
+
import AmdGpuCheckbox from './AmdGpuCheckbox';
|
|
18
|
+
import KmmCheckbox from './KmmCheckbox';
|
|
17
19
|
import {
|
|
18
20
|
FeatureId,
|
|
21
|
+
OPERATOR_NAME_AMD_GPU,
|
|
19
22
|
OPERATOR_NAME_AUTHORINO,
|
|
20
23
|
OPERATOR_NAME_CNV,
|
|
24
|
+
OPERATOR_NAME_KMM,
|
|
21
25
|
OPERATOR_NAME_LSO,
|
|
22
26
|
OPERATOR_NAME_LVM,
|
|
23
27
|
OPERATOR_NAME_MCE,
|
|
@@ -66,6 +70,8 @@ export const operatorComponentMap: Record<string, (props: OperatorProps) => JSX.
|
|
|
66
70
|
pipelines: (props) => <PipelinesCheckbox {...props} />,
|
|
67
71
|
servicemesh: (props) => <ServiceMeshCheckbox {...props} />,
|
|
68
72
|
'nvidia-gpu': (props) => <NvidiaGpuCheckbox {...props} />,
|
|
73
|
+
'amd-gpu': (props) => <AmdGpuCheckbox {...props} />,
|
|
74
|
+
kmm: (props) => <KmmCheckbox {...props} />,
|
|
69
75
|
};
|
|
70
76
|
|
|
71
77
|
export const mapOperatorsToFieldIds: { [key: string]: string } = {
|
|
@@ -84,6 +90,8 @@ export const mapOperatorsToFieldIds: { [key: string]: string } = {
|
|
|
84
90
|
[OPERATOR_NAME_PIPELINES]: 'usePipelines',
|
|
85
91
|
[OPERATOR_NAME_SERVICEMESH]: 'useServicemesh',
|
|
86
92
|
[OPERATOR_NAME_NVIDIA_GPU]: 'useNvidiaGpu',
|
|
93
|
+
[OPERATOR_NAME_AMD_GPU]: 'useAmdGpu',
|
|
94
|
+
[OPERATOR_NAME_KMM]: 'useKmm',
|
|
87
95
|
};
|
|
88
96
|
|
|
89
97
|
export const mapOperatorIdToFeatureId: { [key: string]: FeatureId } = {
|
|
@@ -102,4 +110,6 @@ export const mapOperatorIdToFeatureId: { [key: string]: FeatureId } = {
|
|
|
102
110
|
[OPERATOR_NAME_PIPELINES]: 'PIPELINES',
|
|
103
111
|
[OPERATOR_NAME_SERVICEMESH]: 'SERVICEMESH',
|
|
104
112
|
[OPERATOR_NAME_NVIDIA_GPU]: 'NVIDIA_GPU',
|
|
113
|
+
[OPERATOR_NAME_AMD_GPU]: 'AMD_GPU',
|
|
114
|
+
[OPERATOR_NAME_KMM]: 'KMM',
|
|
105
115
|
};
|
|
@@ -5,8 +5,10 @@ import { Formik, FormikConfig, useFormikContext } from 'formik';
|
|
|
5
5
|
import {
|
|
6
6
|
ClusterWizardStep,
|
|
7
7
|
getFormikErrorFields,
|
|
8
|
+
OPERATOR_NAME_AMD_GPU,
|
|
8
9
|
OPERATOR_NAME_AUTHORINO,
|
|
9
10
|
OPERATOR_NAME_CNV,
|
|
11
|
+
OPERATOR_NAME_KMM,
|
|
10
12
|
OPERATOR_NAME_LSO,
|
|
11
13
|
OPERATOR_NAME_LVM,
|
|
12
14
|
OPERATOR_NAME_MCE,
|
|
@@ -56,6 +58,8 @@ export const getOperatorsInitialValues = (
|
|
|
56
58
|
usePipelines: isOperatorEnabled([OPERATOR_NAME_PIPELINES]),
|
|
57
59
|
useServicemesh: isOperatorEnabled([OPERATOR_NAME_SERVICEMESH]),
|
|
58
60
|
useNvidiaGpu: isOperatorEnabled([OPERATOR_NAME_NVIDIA_GPU]),
|
|
61
|
+
useAmdGpu: isOperatorEnabled([OPERATOR_NAME_AMD_GPU]),
|
|
62
|
+
useKmm: isOperatorEnabled([OPERATOR_NAME_KMM]),
|
|
59
63
|
};
|
|
60
64
|
};
|
|
61
65
|
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
/* eslint-disable no-console */
|
|
2
1
|
import React, { useEffect, useState } from 'react';
|
|
3
2
|
import { useSelector } from 'react-redux';
|
|
4
3
|
import {
|
|
@@ -49,6 +48,7 @@ import {
|
|
|
49
48
|
getOpenShiftAIIncompatibleWithLvmsReason,
|
|
50
49
|
} from '../featureSupportLevels/featureStateUtils';
|
|
51
50
|
import OpenshiftAINvidiaRequirements from '../clusterConfiguration/operators/OpenshiftAINvidiaRequirements';
|
|
51
|
+
import OpenshiftAIAmdRequirements from '../clusterConfiguration/operators/OpenshiftAIAmdRequirements';
|
|
52
52
|
import VirtualizationRequirements from '../clusterConfiguration/operators/VirtualizationRequirements';
|
|
53
53
|
|
|
54
54
|
const operatorsThatCanNotBeInstalledAlone = [
|
|
@@ -78,8 +78,6 @@ export const OperatorsStep = (props: ClusterOperatorProps) => {
|
|
|
78
78
|
const { updateUISettings, uiSettings } = useClusterWizardContext();
|
|
79
79
|
const { values, setFieldValue } = useFormikContext<OperatorsValues>();
|
|
80
80
|
const featureSupportLevelData = useNewFeatureSupportLevel();
|
|
81
|
-
const [hasUnsupportedOperators, setHasUnsupportedOperators] = useState<boolean>(false);
|
|
82
|
-
const [hasIncompatibleOperators, setHasIncompatibleOperators] = useState<boolean>(false);
|
|
83
81
|
|
|
84
82
|
useEffect(() => {
|
|
85
83
|
const fetchBundles = async () => {
|
|
@@ -89,7 +87,7 @@ export const OperatorsStep = (props: ClusterOperatorProps) => {
|
|
|
89
87
|
setBundles(fetchedBundles);
|
|
90
88
|
} catch (error) {
|
|
91
89
|
// eslint-disable-next-line no-console
|
|
92
|
-
console.error('Error
|
|
90
|
+
console.error('Error getting bundles:', error);
|
|
93
91
|
}
|
|
94
92
|
};
|
|
95
93
|
|
|
@@ -105,7 +103,7 @@ export const OperatorsStep = (props: ClusterOperatorProps) => {
|
|
|
105
103
|
setSupportedOperators(sortedOperators);
|
|
106
104
|
} catch (error) {
|
|
107
105
|
// eslint-disable-next-line no-console
|
|
108
|
-
console.error('Error
|
|
106
|
+
console.error('Error getting operators:', error);
|
|
109
107
|
}
|
|
110
108
|
};
|
|
111
109
|
|
|
@@ -191,23 +189,34 @@ export const OperatorsStep = (props: ClusterOperatorProps) => {
|
|
|
191
189
|
setBundleOperators(newBundleOperators);
|
|
192
190
|
};
|
|
193
191
|
|
|
194
|
-
const getBundleLabel = (
|
|
192
|
+
const getBundleLabel = (bundle: Bundle) => {
|
|
193
|
+
let requirements: React.ReactElement | null = null;
|
|
194
|
+
switch (bundle.id) {
|
|
195
|
+
case 'virtualization':
|
|
196
|
+
requirements = <VirtualizationRequirements />;
|
|
197
|
+
break;
|
|
198
|
+
case 'openshift-ai-nvidia':
|
|
199
|
+
requirements = <OpenshiftAINvidiaRequirements />;
|
|
200
|
+
break;
|
|
201
|
+
case 'openshift-ai-amd':
|
|
202
|
+
requirements = <OpenshiftAIAmdRequirements />;
|
|
203
|
+
break;
|
|
204
|
+
}
|
|
205
|
+
|
|
195
206
|
return (
|
|
196
207
|
<>
|
|
197
|
-
<span>{title} </span>
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
}
|
|
210
|
-
/>
|
|
208
|
+
<span>{bundle.title} </span>
|
|
209
|
+
{requirements && (
|
|
210
|
+
<PopoverIcon
|
|
211
|
+
component={'a'}
|
|
212
|
+
bodyContent={
|
|
213
|
+
<>
|
|
214
|
+
<span style={{ fontSize: '1.1em' }}>{'Requirements and dependencies'}</span>
|
|
215
|
+
{requirements}
|
|
216
|
+
</>
|
|
217
|
+
}
|
|
218
|
+
/>
|
|
219
|
+
)}
|
|
211
220
|
</>
|
|
212
221
|
);
|
|
213
222
|
};
|
|
@@ -265,28 +274,19 @@ export const OperatorsStep = (props: ClusterOperatorProps) => {
|
|
|
265
274
|
);
|
|
266
275
|
|
|
267
276
|
const bundleHasOperatorsNotCompatibles = React.useCallback(
|
|
268
|
-
(operators: string[] | undefined, values: OperatorsValues) => {
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
277
|
+
(operators: string[] | undefined, values: OperatorsValues, isSelected: boolean) => {
|
|
278
|
+
if (!isSelected) {
|
|
279
|
+
return (
|
|
280
|
+
operators?.some((operatorKey) => {
|
|
281
|
+
const disabledReason = getDisabledReasonForOperator(operatorKey, values);
|
|
282
|
+
return disabledReason !== undefined;
|
|
283
|
+
}) ?? false
|
|
284
|
+
);
|
|
285
|
+
} else return false;
|
|
276
286
|
},
|
|
277
287
|
[getDisabledReasonForOperator],
|
|
278
288
|
);
|
|
279
289
|
|
|
280
|
-
useEffect(() => {
|
|
281
|
-
setHasUnsupportedOperators(
|
|
282
|
-
bundles.some((bundle) => bundleHasOperatorsNotSupported(bundle.operators)),
|
|
283
|
-
);
|
|
284
|
-
|
|
285
|
-
setHasIncompatibleOperators(
|
|
286
|
-
bundles.some((bundle) => bundleHasOperatorsNotCompatibles(bundle.operators, values)),
|
|
287
|
-
);
|
|
288
|
-
}, [values, bundles, bundleHasOperatorsNotSupported, bundleHasOperatorsNotCompatibles]);
|
|
289
|
-
|
|
290
290
|
return (
|
|
291
291
|
<Stack hasGutter data-testid={'operators-page'}>
|
|
292
292
|
<StackItem>
|
|
@@ -316,22 +316,36 @@ export const OperatorsStep = (props: ClusterOperatorProps) => {
|
|
|
316
316
|
{/* Mostrar bundles como tarjetas */}
|
|
317
317
|
<Gallery hasGutter minWidths={{ default: '350px' }} maxWidths={{ default: '2fr' }}>
|
|
318
318
|
{filteredBundles.map((bundle) => {
|
|
319
|
-
const isSnoAndBlockedBundle =
|
|
319
|
+
const isSnoAndBlockedBundle =
|
|
320
|
+
isSNO && (bundle.id === 'openshift-ai-nvidia' || bundle.id === 'openshift-ai-amd');
|
|
321
|
+
const hasUnsupportedOperators = bundleHasOperatorsNotSupported(bundle.operators);
|
|
322
|
+
const hasIncompatibleOperators = bundleHasOperatorsNotCompatibles(
|
|
323
|
+
bundle.operators,
|
|
324
|
+
values,
|
|
325
|
+
bundle.id ? selectedBundles[bundle.id] : false,
|
|
326
|
+
);
|
|
327
|
+
const hasAnotherAIBundleSelected =
|
|
328
|
+
(bundle.id === 'openshift-ai-nvidia' && selectedBundles['openshift-ai-amd']) ||
|
|
329
|
+
(bundle.id === 'openshift-ai-amd' && selectedBundles['openshift-ai-nvidia']);
|
|
320
330
|
|
|
321
331
|
const tooltipContent = hasUnsupportedOperators
|
|
322
332
|
? 'Some operators in this bundle are not supported with the current configuration.'
|
|
323
|
-
: hasIncompatibleOperators
|
|
324
|
-
? 'Some operators in this bundle can not be installed with some single operators selected.'
|
|
325
333
|
: isSnoAndBlockedBundle
|
|
326
334
|
? 'This bundle is not available when deploying a Single Node OpenShift.'
|
|
335
|
+
: hasIncompatibleOperators
|
|
336
|
+
? 'Some operators in this bundle can not be installed with some single operators selected.'
|
|
337
|
+
: hasAnotherAIBundleSelected
|
|
338
|
+
? 'This bundle cannot be selected because you already have another Openshift AI bundle selected.'
|
|
327
339
|
: '';
|
|
328
|
-
|
|
329
340
|
return (
|
|
330
341
|
<GalleryItem key={bundle.id}>
|
|
331
342
|
<Tooltip
|
|
332
343
|
content={tooltipContent}
|
|
333
344
|
hidden={
|
|
334
|
-
!hasUnsupportedOperators &&
|
|
345
|
+
!hasUnsupportedOperators &&
|
|
346
|
+
!hasIncompatibleOperators &&
|
|
347
|
+
!isSnoAndBlockedBundle &&
|
|
348
|
+
!hasAnotherAIBundleSelected
|
|
335
349
|
}
|
|
336
350
|
>
|
|
337
351
|
<Card
|
|
@@ -341,7 +355,10 @@ export const OperatorsStep = (props: ClusterOperatorProps) => {
|
|
|
341
355
|
: { height: '200px' }
|
|
342
356
|
}
|
|
343
357
|
isDisabled={
|
|
344
|
-
hasUnsupportedOperators ||
|
|
358
|
+
hasUnsupportedOperators ||
|
|
359
|
+
hasIncompatibleOperators ||
|
|
360
|
+
isSnoAndBlockedBundle ||
|
|
361
|
+
hasAnotherAIBundleSelected
|
|
345
362
|
}
|
|
346
363
|
>
|
|
347
364
|
<CardTitle
|
|
@@ -352,7 +369,7 @@ export const OperatorsStep = (props: ClusterOperatorProps) => {
|
|
|
352
369
|
}}
|
|
353
370
|
>
|
|
354
371
|
<div style={{ display: 'flex', alignItems: 'center', gap: '8px' }}>
|
|
355
|
-
{getBundleLabel(bundle
|
|
372
|
+
{getBundleLabel(bundle)}
|
|
356
373
|
</div>
|
|
357
374
|
<Checkbox
|
|
358
375
|
id={`bundle-${bundle.id || ''}`}
|
|
@@ -361,7 +378,10 @@ export const OperatorsStep = (props: ClusterOperatorProps) => {
|
|
|
361
378
|
void handleBundleSelection(bundle.id || '', bundle.operators || [], checked)
|
|
362
379
|
}
|
|
363
380
|
isDisabled={
|
|
364
|
-
hasUnsupportedOperators ||
|
|
381
|
+
hasUnsupportedOperators ||
|
|
382
|
+
hasIncompatibleOperators ||
|
|
383
|
+
isSnoAndBlockedBundle ||
|
|
384
|
+
hasAnotherAIBundleSelected
|
|
365
385
|
}
|
|
366
386
|
/>
|
|
367
387
|
</CardTitle>
|
|
@@ -377,7 +397,8 @@ export const OperatorsStep = (props: ClusterOperatorProps) => {
|
|
|
377
397
|
|
|
378
398
|
{/* Badge aligned to the bottom-left */}
|
|
379
399
|
<div style={{ marginTop: '10px', alignSelf: 'flex-end', height: '25px' }}>
|
|
380
|
-
{bundle.id === 'openshift-ai-nvidia'
|
|
400
|
+
{(bundle.id === 'openshift-ai-nvidia' ||
|
|
401
|
+
bundle.id === 'openshift-ai-amd') && (
|
|
381
402
|
<NewFeatureSupportLevelBadge
|
|
382
403
|
featureId="OPENSHIFT_AI"
|
|
383
404
|
supportLevel="dev-preview"
|
|
@@ -92,6 +92,11 @@ const validationInfoHostsDisovery: ValidationsInfo = {
|
|
|
92
92
|
message: 'a validation unrelated to the canNextHostDiscovery',
|
|
93
93
|
status: 'error',
|
|
94
94
|
},
|
|
95
|
+
{
|
|
96
|
+
id: 'amd-gpu-requirements-satisfied',
|
|
97
|
+
message: 'a validation message',
|
|
98
|
+
status: 'success',
|
|
99
|
+
},
|
|
95
100
|
],
|
|
96
101
|
};
|
|
97
102
|
|
|
@@ -205,6 +210,11 @@ const flatValidationHostsDiscovery: HostValidation[] = [
|
|
|
205
210
|
message: 'a host validation message',
|
|
206
211
|
status: 'success',
|
|
207
212
|
},
|
|
213
|
+
{
|
|
214
|
+
id: 'amd-gpu-requirements-satisfied',
|
|
215
|
+
message: 'a host validation message',
|
|
216
|
+
status: 'success',
|
|
217
|
+
},
|
|
208
218
|
];
|
|
209
219
|
|
|
210
220
|
const flatValidationHostsStorage: HostValidation[] = [
|
|
@@ -174,6 +174,7 @@ const hostDiscoveryStepValidationsMap: WizardStepValidationMap = {
|
|
|
174
174
|
'nvidia-gpu-requirements-satisfied',
|
|
175
175
|
'openshift-ai-requirements-satisfied',
|
|
176
176
|
'osc-requirements-satisfied',
|
|
177
|
+
'amd-gpu-requirements-satisfied',
|
|
177
178
|
],
|
|
178
179
|
},
|
|
179
180
|
host: {
|
|
@@ -189,6 +190,7 @@ const hostDiscoveryStepValidationsMap: WizardStepValidationMap = {
|
|
|
189
190
|
'nvidia-gpu-requirements-satisfied',
|
|
190
191
|
'openshift-ai-requirements-satisfied',
|
|
191
192
|
'osc-requirements-satisfied',
|
|
193
|
+
'amd-gpu-requirements-satisfied',
|
|
192
194
|
],
|
|
193
195
|
},
|
|
194
196
|
softValidationIds: ['no-skip-installation-disk', 'no-skip-missing-disk', 'compatible-agent'],
|
|
@@ -289,6 +289,11 @@ export const getNewFeatureDisabledReason = (
|
|
|
289
289
|
return `Service mesh is not available with the selected CPU architecture.`;
|
|
290
290
|
}
|
|
291
291
|
}
|
|
292
|
+
case 'AMD_GPU': {
|
|
293
|
+
if (!isSupported) {
|
|
294
|
+
return `AMD GPU is not available with the selected CPU architecture.`;
|
|
295
|
+
}
|
|
296
|
+
}
|
|
292
297
|
default: {
|
|
293
298
|
return undefined;
|
|
294
299
|
}
|
|
@@ -16,6 +16,8 @@ import {
|
|
|
16
16
|
OPERATOR_NAME_PIPELINES,
|
|
17
17
|
OPERATOR_NAME_SERVICEMESH,
|
|
18
18
|
OPERATOR_NAME_NVIDIA_GPU,
|
|
19
|
+
OPERATOR_NAME_AMD_GPU,
|
|
20
|
+
OPERATOR_NAME_KMM,
|
|
19
21
|
} from '../../common';
|
|
20
22
|
import { getOlmOperatorCreateParamsByName } from '../components/clusters/utils';
|
|
21
23
|
import {
|
|
@@ -52,6 +54,8 @@ const OperatorsService = {
|
|
|
52
54
|
setOperator(OPERATOR_NAME_PIPELINES, values.usePipelines);
|
|
53
55
|
setOperator(OPERATOR_NAME_SERVICEMESH, values.useServicemesh);
|
|
54
56
|
setOperator(OPERATOR_NAME_NVIDIA_GPU, values.useNvidiaGpu);
|
|
57
|
+
setOperator(OPERATOR_NAME_AMD_GPU, values.useAmdGpu);
|
|
58
|
+
setOperator(OPERATOR_NAME_KMM, values.useKmm);
|
|
55
59
|
|
|
56
60
|
return Object.values(enabledOlmOperatorsByName);
|
|
57
61
|
},
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"dependencies": {
|
|
3
|
-
"@openshift-assisted/locales": "2.38.
|
|
4
|
-
"@openshift-assisted/types": "2.38.
|
|
3
|
+
"@openshift-assisted/locales": "2.38.4",
|
|
4
|
+
"@openshift-assisted/types": "2.38.4",
|
|
5
5
|
"@openshift-console/dynamic-plugin-sdk": "0.0.3",
|
|
6
6
|
"@patternfly/patternfly": "5.2.0",
|
|
7
7
|
"@patternfly/react-code-editor": "5.2.0",
|
|
@@ -139,5 +139,5 @@
|
|
|
139
139
|
]
|
|
140
140
|
}
|
|
141
141
|
},
|
|
142
|
-
"version": "2.38.
|
|
142
|
+
"version": "2.38.4"
|
|
143
143
|
}
|