@openshift-assisted/ui-lib 2.42.3 → 2.43.0
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/ClusterDeploymentDetailsStep.d.ts.map +1 -1
- package/build/@types/cim/components/ClusterDeployment/ClusterDetailsFormFields.d.ts.map +1 -1
- package/build/@types/common/components/clusterConfiguration/index.d.ts +0 -2
- package/build/@types/common/components/clusterConfiguration/index.d.ts.map +1 -1
- package/build/@types/common/components/clusterWizard/clusterDetailsValidation.d.ts +1 -4
- package/build/@types/common/components/clusterWizard/clusterDetailsValidation.d.ts.map +1 -1
- package/build/@types/common/components/clusterWizard/types.d.ts +0 -2
- package/build/@types/common/components/clusterWizard/types.d.ts.map +1 -1
- package/build/@types/common/components/hosts/DiskRole.d.ts.map +1 -1
- package/build/@types/common/components/hosts/TableToolbar.d.ts.map +1 -1
- package/build/@types/common/components/operators/operatorSpecs.d.ts.map +1 -1
- package/build/@types/common/components/ui/SimpleDropdown.d.ts.map +1 -1
- package/build/@types/common/components/ui/formik/index.d.ts +0 -1
- package/build/@types/common/components/ui/formik/index.d.ts.map +1 -1
- package/build/@types/common/config/constants.d.ts.map +1 -1
- package/build/@types/common/config/docs_links.d.ts +3 -3
- package/build/@types/common/config/docs_links.d.ts.map +1 -1
- package/build/@types/common/selectors/clusterSelectors.d.ts +1 -1
- package/build/@types/common/selectors/clusterSelectors.d.ts.map +1 -1
- package/build/@types/common/types/cpuArchitecture.d.ts.map +1 -1
- package/build/@types/ocm/components/Routes.d.ts +2 -1
- package/build/@types/ocm/components/Routes.d.ts.map +1 -1
- package/build/@types/ocm/components/clusterConfiguration/ControlPlaneNodesDropdown.d.ts.map +1 -1
- package/build/@types/ocm/components/clusterConfiguration/OcmSNODisclaimer.d.ts +1 -4
- package/build/@types/ocm/components/clusterConfiguration/OcmSNODisclaimer.d.ts.map +1 -1
- package/build/@types/ocm/components/clusterConfiguration/networkConfiguration/SubnetsDropdown.d.ts.map +1 -1
- package/build/@types/ocm/components/clusterWizard/ClusterDetailsForm.d.ts.map +1 -1
- package/build/@types/ocm/components/clusterWizard/CredentialsDownload.d.ts.map +1 -1
- package/build/@types/ocm/components/clusterWizard/Operators.d.ts.map +1 -1
- package/build/@types/ocm/components/clusters/AssistedInstallerHeader.d.ts.map +1 -1
- package/build/@types/ocm/components/clusters/ClusterPage.d.ts.map +1 -1
- package/build/@types/ocm/components/clusters/NewClusterPage.d.ts.map +1 -1
- package/build/@types/ocm/components/hosts/use-hosts-table.d.ts.map +1 -1
- package/build/@types/ocm/services/OperatorsService.d.ts.map +1 -1
- package/build/@types/ocm/store/slices/current-cluster/selectors.d.ts.map +1 -1
- package/build/@types/ocm/store/slices/current-cluster/slice.d.ts +1 -1
- package/build/cjs/cim/components/ClusterDeployment/ClusterDeploymentDetailsStep.js +1 -4
- package/build/cjs/cim/components/ClusterDeployment/ClusterDeploymentDetailsStep.js.map +1 -1
- package/build/cjs/cim/components/ClusterDeployment/ClusterDetailsFormFields.js +9 -1
- package/build/cjs/cim/components/ClusterDeployment/ClusterDetailsFormFields.js.map +1 -1
- package/build/cjs/common/components/clusterConfiguration/index.js +1 -5
- package/build/cjs/common/components/clusterConfiguration/index.js.map +1 -1
- package/build/cjs/common/components/clusterWizard/clusterDetailsValidation.js +3 -23
- package/build/cjs/common/components/clusterWizard/clusterDetailsValidation.js.map +1 -1
- package/build/cjs/common/components/hosts/DiskRole.js +1 -1
- package/build/cjs/common/components/hosts/DiskRole.js.map +1 -1
- package/build/cjs/common/components/hosts/TableToolbar.js +3 -3
- package/build/cjs/common/components/hosts/TableToolbar.js.map +1 -1
- package/build/cjs/common/components/operators/operatorSpecs.js +5 -3
- package/build/cjs/common/components/operators/operatorSpecs.js.map +1 -1
- package/build/cjs/common/components/ui/OpenShiftVersionDropdown.js +6 -7
- package/build/cjs/common/components/ui/OpenShiftVersionDropdown.js.map +1 -1
- package/build/cjs/common/components/ui/SimpleDropdown.js +1 -1
- package/build/cjs/common/components/ui/SimpleDropdown.js.map +1 -1
- package/build/cjs/common/components/ui/formik/index.js +1 -3
- package/build/cjs/common/components/ui/formik/index.js.map +1 -1
- package/build/cjs/common/config/constants.js +0 -4
- package/build/cjs/common/config/constants.js.map +1 -1
- package/build/cjs/common/config/docs_links.js +13 -9
- package/build/cjs/common/config/docs_links.js.map +1 -1
- package/build/cjs/common/selectors/clusterSelectors.js +1 -1
- package/build/cjs/common/selectors/clusterSelectors.js.map +1 -1
- package/build/cjs/common/types/cpuArchitecture.js +3 -5
- package/build/cjs/common/types/cpuArchitecture.js.map +1 -1
- package/build/cjs/ocm/components/Routes.js +3 -2
- package/build/cjs/ocm/components/Routes.js.map +1 -1
- package/build/cjs/ocm/components/clusterConfiguration/ControlPlaneNodesDropdown.js +2 -4
- package/build/cjs/ocm/components/clusterConfiguration/ControlPlaneNodesDropdown.js.map +1 -1
- package/build/cjs/ocm/components/clusterConfiguration/OcmSNODisclaimer.js +5 -21
- package/build/cjs/ocm/components/clusterConfiguration/OcmSNODisclaimer.js.map +1 -1
- package/build/cjs/ocm/components/clusterConfiguration/networkConfiguration/SubnetsDropdown.js +12 -18
- package/build/cjs/ocm/components/clusterConfiguration/networkConfiguration/SubnetsDropdown.js.map +1 -1
- package/build/cjs/ocm/components/clusterConfiguration/staticIp/commonValidationSchemas.js +1 -1
- package/build/cjs/ocm/components/clusterConfiguration/staticIp/commonValidationSchemas.js.map +1 -1
- package/build/cjs/ocm/components/clusterConfiguration/staticIp/components/FormViewNetworkWide/FormViewNetworkWideFields.js +1 -1
- package/build/cjs/ocm/components/clusterConfiguration/staticIp/components/FormViewNetworkWide/FormViewNetworkWideFields.js.map +1 -1
- package/build/cjs/ocm/components/clusterConfiguration/staticIp/components/staticIp.css +3 -3
- package/build/cjs/ocm/components/clusterConfiguration/staticIp/data/formDataToInfraEnvField.js +1 -1
- package/build/cjs/ocm/components/clusterConfiguration/staticIp/data/formDataToInfraEnvField.js.map +1 -1
- package/build/cjs/ocm/components/clusterDetail/ProgressBarAlerts.js +1 -1
- package/build/cjs/ocm/components/clusterDetail/ProgressBarAlerts.js.map +1 -1
- package/build/cjs/ocm/components/clusterWizard/ClusterDetailsForm.js +0 -1
- package/build/cjs/ocm/components/clusterWizard/ClusterDetailsForm.js.map +1 -1
- package/build/cjs/ocm/components/clusterWizard/CredentialsDownload.js +2 -1
- package/build/cjs/ocm/components/clusterWizard/CredentialsDownload.js.map +1 -1
- package/build/cjs/ocm/components/clusterWizard/Operators.js +4 -1
- package/build/cjs/ocm/components/clusterWizard/Operators.js.map +1 -1
- package/build/cjs/ocm/components/clusters/AssistedInstallerHeader.js +3 -0
- package/build/cjs/ocm/components/clusters/AssistedInstallerHeader.js.map +1 -1
- package/build/cjs/ocm/components/clusters/ClusterPage.js +2 -0
- package/build/cjs/ocm/components/clusters/ClusterPage.js.map +1 -1
- package/build/cjs/ocm/components/clusters/NewClusterPage.js +6 -7
- package/build/cjs/ocm/components/clusters/NewClusterPage.js.map +1 -1
- package/build/cjs/ocm/components/hosts/use-hosts-table.js +8 -1
- package/build/cjs/ocm/components/hosts/use-hosts-table.js.map +1 -1
- package/build/cjs/ocm/services/DiskEncryptionService.js +1 -1
- package/build/cjs/ocm/services/DiskEncryptionService.js.map +1 -1
- package/build/cjs/ocm/services/OperatorsService.js +12 -2
- package/build/cjs/ocm/services/OperatorsService.js.map +1 -1
- package/build/cjs/ocm/store/slices/current-cluster/selectors.js +1 -1
- package/build/cjs/ocm/store/slices/current-cluster/selectors.js.map +1 -1
- package/lib/cim/components/ClusterDeployment/ClusterDeploymentDetailsStep.tsx +1 -5
- package/lib/cim/components/ClusterDeployment/ClusterDetailsFormFields.tsx +11 -2
- package/lib/common/components/clusterConfiguration/index.ts +0 -2
- package/lib/common/components/clusterWizard/clusterDetailsValidation.ts +2 -33
- package/lib/common/components/clusterWizard/types.ts +0 -2
- package/lib/common/components/hosts/DiskRole.tsx +0 -1
- package/lib/common/components/hosts/TableToolbar.tsx +9 -10
- package/lib/common/components/operators/operatorSpecs.tsx +6 -4
- package/lib/common/components/ui/OpenShiftVersionDropdown.tsx +10 -10
- package/lib/common/components/ui/SimpleDropdown.tsx +0 -1
- package/lib/common/components/ui/formik/index.tsx +0 -1
- package/lib/common/config/constants.ts +0 -4
- package/lib/common/config/docs_links.ts +15 -15
- package/lib/common/selectors/clusterSelectors.ts +1 -2
- package/lib/common/types/cpuArchitecture.ts +3 -9
- package/lib/ocm/components/Routes.tsx +3 -0
- package/lib/ocm/components/clusterConfiguration/ControlPlaneNodesDropdown.tsx +3 -16
- package/lib/ocm/components/clusterConfiguration/OcmSNODisclaimer.tsx +14 -60
- package/lib/ocm/components/clusterConfiguration/networkConfiguration/SubnetsDropdown.tsx +18 -25
- package/lib/ocm/components/clusterConfiguration/staticIp/commonValidationSchemas.tsx +1 -1
- package/lib/ocm/components/clusterConfiguration/staticIp/components/FormViewNetworkWide/FormViewNetworkWideFields.tsx +2 -2
- package/lib/ocm/components/clusterConfiguration/staticIp/components/staticIp.css +3 -3
- package/lib/ocm/components/clusterConfiguration/staticIp/data/formDataToInfraEnvField.ts +1 -1
- package/lib/ocm/components/clusterDetail/ProgressBarAlerts.tsx +1 -1
- package/lib/ocm/components/clusterWizard/ClusterDetailsForm.tsx +0 -1
- package/lib/ocm/components/clusterWizard/CredentialsDownload.tsx +2 -1
- package/lib/ocm/components/clusterWizard/Operators.tsx +5 -1
- package/lib/ocm/components/clusters/AssistedInstallerHeader.tsx +9 -1
- package/lib/ocm/components/clusters/ClusterPage.tsx +3 -0
- package/lib/ocm/components/clusters/NewClusterPage.tsx +9 -13
- package/lib/ocm/components/hosts/use-hosts-table.tsx +8 -1
- package/lib/ocm/services/DiskEncryptionService.ts +1 -1
- package/lib/ocm/services/OperatorsService.tsx +18 -2
- package/lib/ocm/store/slices/current-cluster/selectors.ts +1 -1
- package/package.json +3 -3
- package/build/@types/common/components/clusterConfiguration/SNOControlGroup.d.ts +0 -10
- package/build/@types/common/components/clusterConfiguration/SNOControlGroup.d.ts.map +0 -1
- package/build/@types/common/components/clusterConfiguration/SNODisclaimer.d.ts +0 -10
- package/build/@types/common/components/clusterConfiguration/SNODisclaimer.d.ts.map +0 -1
- package/build/@types/common/components/operators/test.d.ts +0 -50
- package/build/@types/common/components/operators/test.d.ts.map +0 -1
- package/build/@types/common/components/ui/formik/SingleNodeCheckbox.d.ts +0 -9
- package/build/@types/common/components/ui/formik/SingleNodeCheckbox.d.ts.map +0 -1
- package/build/@types/ocm/components/clusterConfiguration/OcmSingleNodeCheckbox.d.ts +0 -11
- package/build/@types/ocm/components/clusterConfiguration/OcmSingleNodeCheckbox.d.ts.map +0 -1
- package/build/cjs/common/components/clusterConfiguration/SNOControlGroup.js +0 -20
- package/build/cjs/common/components/clusterConfiguration/SNOControlGroup.js.map +0 -1
- package/build/cjs/common/components/clusterConfiguration/SNODisclaimer.js +0 -31
- package/build/cjs/common/components/clusterConfiguration/SNODisclaimer.js.map +0 -1
- package/build/cjs/common/components/operators/test.js +0 -323
- package/build/cjs/common/components/operators/test.js.map +0 -1
- package/build/cjs/common/components/ui/formik/SingleNodeCheckbox.js +0 -45
- package/build/cjs/common/components/ui/formik/SingleNodeCheckbox.js.map +0 -1
- package/build/cjs/ocm/components/clusterConfiguration/OcmSingleNodeCheckbox.js +0 -51
- package/build/cjs/ocm/components/clusterConfiguration/OcmSingleNodeCheckbox.js.map +0 -1
- package/lib/common/components/clusterConfiguration/SNOControlGroup.tsx +0 -41
- package/lib/common/components/clusterConfiguration/SNODisclaimer.tsx +0 -79
- package/lib/common/components/operators/test.tsx +0 -469
- package/lib/common/components/ui/formik/SingleNodeCheckbox.tsx +0 -98
- package/lib/ocm/components/clusterConfiguration/OcmSingleNodeCheckbox.tsx +0 -107
|
@@ -1,323 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.categories = exports.getOperatorTitleByFeatureId = exports.useOperatorSpecs = exports.getOperatorSpecs = exports.HighlightedText = exports.highlightMatch = exports.isOCPVersionEqualsOrMore = void 0;
|
|
4
|
-
const tslib_1 = require("tslib");
|
|
5
|
-
const react_1 = tslib_1.__importDefault(require("react"));
|
|
6
|
-
const constants_1 = require("../../config/constants");
|
|
7
|
-
const ui_1 = require("../ui");
|
|
8
|
-
const config_1 = require("../../config");
|
|
9
|
-
const utils_1 = require("../../utils");
|
|
10
|
-
const newFeatureSupportLevels_1 = require("../newFeatureSupportLevels");
|
|
11
|
-
const operatorDescriptions_1 = require("./operatorDescriptions");
|
|
12
|
-
// TODO check if it's unused and it can be deleted in favor of "isMajorMinorVersionEqualOrGreater"
|
|
13
|
-
const isOCPVersionEqualsOrMore = (openshiftVersion, ocpVersionToCompare) => {
|
|
14
|
-
const [majorA, minorA] = (0, utils_1.getMajorMinorVersion)(openshiftVersion).split('.');
|
|
15
|
-
const [majorB, minorB] = ocpVersionToCompare.split('.');
|
|
16
|
-
return (Number(majorA) > Number(majorB) ||
|
|
17
|
-
(Number(majorA) === Number(majorB) && Number(minorA) >= Number(minorB)));
|
|
18
|
-
};
|
|
19
|
-
exports.isOCPVersionEqualsOrMore = isOCPVersionEqualsOrMore;
|
|
20
|
-
const highlightMatch = (text, searchTerm) => {
|
|
21
|
-
if (!searchTerm)
|
|
22
|
-
return text;
|
|
23
|
-
const escapeSearchTerm = searchTerm.replace(/[.*+?^${}()|[\]\\]/g, '\\$&');
|
|
24
|
-
const regex = new RegExp(`(${escapeSearchTerm})`, 'gi');
|
|
25
|
-
const parts = text.split(regex);
|
|
26
|
-
return parts.map((part, i) => part.toLowerCase() === searchTerm.toLowerCase() ? react_1.default.createElement("mark", { key: i }, part) : part);
|
|
27
|
-
};
|
|
28
|
-
exports.highlightMatch = highlightMatch;
|
|
29
|
-
const HighlightedText = ({ text, searchTerm }) => (react_1.default.createElement(react_1.default.Fragment, null, (0, exports.highlightMatch)(text, searchTerm)));
|
|
30
|
-
exports.HighlightedText = HighlightedText;
|
|
31
|
-
const getOperatorSpecs = (getFeatureSupportLevel, useLVMS) => {
|
|
32
|
-
return {
|
|
33
|
-
[exports.categories[Category.STORAGE]]: [
|
|
34
|
-
{
|
|
35
|
-
operatorKey: constants_1.OPERATOR_NAME_LSO,
|
|
36
|
-
title: 'Local Storage Operator',
|
|
37
|
-
featureId: 'LSO',
|
|
38
|
-
descriptionText: operatorDescriptions_1.DESCRIPTION_LSO,
|
|
39
|
-
Description: ({ openshiftVersion, searchTerm }) => (react_1.default.createElement(react_1.default.Fragment, null,
|
|
40
|
-
react_1.default.createElement(exports.HighlightedText, { text: operatorDescriptions_1.DESCRIPTION_LSO, searchTerm: searchTerm }),
|
|
41
|
-
' ',
|
|
42
|
-
react_1.default.createElement(ui_1.ExternalLink, { href: (0, config_1.getLsoLink)(openshiftVersion) }, "Learn more"))),
|
|
43
|
-
notStandalone: true,
|
|
44
|
-
supportLevel: getFeatureSupportLevel('LSO'),
|
|
45
|
-
},
|
|
46
|
-
{
|
|
47
|
-
operatorKey: constants_1.OPERATOR_NAME_LVM,
|
|
48
|
-
title: useLVMS ? 'Logical Volume Manager Storage' : 'Logical Volume Manager',
|
|
49
|
-
featureId: 'LVM',
|
|
50
|
-
descriptionText: operatorDescriptions_1.DESCRIPTION_LVM,
|
|
51
|
-
Description: ({ openshiftVersion, searchTerm }) => useLVMS ? (react_1.default.createElement(react_1.default.Fragment, null,
|
|
52
|
-
react_1.default.createElement(exports.HighlightedText, { text: operatorDescriptions_1.DESCRIPTION_LVM, searchTerm: searchTerm }),
|
|
53
|
-
' ',
|
|
54
|
-
react_1.default.createElement(ui_1.ExternalLink, { href: (0, config_1.getLvmsDocsLink)(openshiftVersion) }, "Learn more"))) : (react_1.default.createElement(react_1.default.Fragment, null, operatorDescriptions_1.DESCRIPTION_LVM)),
|
|
55
|
-
supportLevel: getFeatureSupportLevel('LVM'),
|
|
56
|
-
},
|
|
57
|
-
{
|
|
58
|
-
operatorKey: constants_1.OPERATOR_NAME_ODF,
|
|
59
|
-
title: 'OpenShift Data Foundation',
|
|
60
|
-
featureId: 'ODF',
|
|
61
|
-
descriptionText: operatorDescriptions_1.DESCRIPTION_ODF,
|
|
62
|
-
Requirements: () => (react_1.default.createElement(ui_1.ExternalLink, { href: config_1.ODF_REQUIREMENTS_LINK }, "Learn more about the requirements for OpenShift Data Foundation")),
|
|
63
|
-
Description: ({ searchTerm }) => (react_1.default.createElement(react_1.default.Fragment, null,
|
|
64
|
-
react_1.default.createElement(exports.HighlightedText, { text: operatorDescriptions_1.DESCRIPTION_ODF, searchTerm: searchTerm }),
|
|
65
|
-
' ',
|
|
66
|
-
react_1.default.createElement(ui_1.ExternalLink, { href: config_1.ODF_LINK }, "Learn more"))),
|
|
67
|
-
supportLevel: getFeatureSupportLevel('ODF'),
|
|
68
|
-
},
|
|
69
|
-
],
|
|
70
|
-
[exports.categories[Category.VIRT]]: [
|
|
71
|
-
{
|
|
72
|
-
operatorKey: constants_1.OPERATOR_NAME_CNV,
|
|
73
|
-
title: 'OpenShift Virtualization',
|
|
74
|
-
featureId: 'CNV',
|
|
75
|
-
descriptionText: operatorDescriptions_1.DESCRIPTION_CNV,
|
|
76
|
-
Requirements: () => (react_1.default.createElement(react_1.default.Fragment, null, "Enabled CPU virtualization support in BIOS (Intel-VT / AMD-V) on all nodes")),
|
|
77
|
-
Description: ({ searchTerm }) => (react_1.default.createElement(react_1.default.Fragment, null,
|
|
78
|
-
react_1.default.createElement(exports.HighlightedText, { text: operatorDescriptions_1.DESCRIPTION_CNV, searchTerm: searchTerm }),
|
|
79
|
-
' ',
|
|
80
|
-
react_1.default.createElement(ui_1.ExternalLink, { href: config_1.CNV_LINK }, "Learn more"))),
|
|
81
|
-
supportLevel: getFeatureSupportLevel('CNV'),
|
|
82
|
-
},
|
|
83
|
-
{
|
|
84
|
-
operatorKey: constants_1.OPERATOR_NAME_MTV,
|
|
85
|
-
title: 'Migration Toolkit for Virtualization',
|
|
86
|
-
featureId: 'MTV',
|
|
87
|
-
descriptionText: operatorDescriptions_1.DESCRIPTION_MTV,
|
|
88
|
-
Description: ({ searchTerm }) => (react_1.default.createElement(react_1.default.Fragment, null,
|
|
89
|
-
react_1.default.createElement(exports.HighlightedText, { text: operatorDescriptions_1.DESCRIPTION_MTV, searchTerm: searchTerm }),
|
|
90
|
-
' ',
|
|
91
|
-
react_1.default.createElement(ui_1.ExternalLink, { href: config_1.MTV_LINK }, "Learn more"))),
|
|
92
|
-
supportLevel: getFeatureSupportLevel('MTV'),
|
|
93
|
-
},
|
|
94
|
-
{
|
|
95
|
-
operatorKey: constants_1.OPERATOR_NAME_OSC,
|
|
96
|
-
title: 'OpenShift sandboxed containers',
|
|
97
|
-
featureId: 'OSC',
|
|
98
|
-
descriptionText: operatorDescriptions_1.DESCRIPTION_OSC,
|
|
99
|
-
Requirements: () => (react_1.default.createElement(ui_1.ExternalLink, { href: config_1.OSC_REQUIREMENTS_LINK }, "Learn more about the requirements for OpenShift sandboxed containers")),
|
|
100
|
-
Description: () => (react_1.default.createElement(react_1.default.Fragment, null,
|
|
101
|
-
operatorDescriptions_1.DESCRIPTION_OSC,
|
|
102
|
-
" ",
|
|
103
|
-
react_1.default.createElement(ui_1.ExternalLink, { href: config_1.OSC_LINK }, "Learn more"))),
|
|
104
|
-
supportLevel: getFeatureSupportLevel('OSC'),
|
|
105
|
-
},
|
|
106
|
-
],
|
|
107
|
-
[exports.categories[Category.AI]]: [
|
|
108
|
-
{
|
|
109
|
-
operatorKey: constants_1.OPERATOR_NAME_OPENSHIFT_AI,
|
|
110
|
-
title: 'OpenShift AI',
|
|
111
|
-
featureId: 'OPENSHIFT_AI',
|
|
112
|
-
descriptionText: operatorDescriptions_1.DESCRIPTION_OPENSHIFT_AI,
|
|
113
|
-
Requirements: () => (react_1.default.createElement(ui_1.ExternalLink, { href: config_1.OPENSHIFT_AI_REQUIREMENTS_LINK }, "Learn more")),
|
|
114
|
-
Description: ({ searchTerm }) => (react_1.default.createElement(react_1.default.Fragment, null,
|
|
115
|
-
react_1.default.createElement(exports.HighlightedText, { text: operatorDescriptions_1.DESCRIPTION_OPENSHIFT_AI, searchTerm: searchTerm }),
|
|
116
|
-
' ',
|
|
117
|
-
react_1.default.createElement(ui_1.ExternalLink, { href: config_1.OPENSHIFT_AI_LINK }, "Learn more"))),
|
|
118
|
-
supportLevel: getFeatureSupportLevel('OPENSHIFT_AI'),
|
|
119
|
-
},
|
|
120
|
-
{
|
|
121
|
-
operatorKey: constants_1.OPERATOR_NAME_AMD_GPU,
|
|
122
|
-
title: 'AMD GPU',
|
|
123
|
-
featureId: 'AMD_GPU',
|
|
124
|
-
descriptionText: operatorDescriptions_1.DESCRIPTION_AMD_GPU,
|
|
125
|
-
Requirements: () => react_1.default.createElement(react_1.default.Fragment, null, "Requires at least one supported AMD GPU"),
|
|
126
|
-
Description: ({ searchTerm }) => (react_1.default.createElement(react_1.default.Fragment, null,
|
|
127
|
-
' ',
|
|
128
|
-
react_1.default.createElement(exports.HighlightedText, { text: operatorDescriptions_1.DESCRIPTION_AMD_GPU, searchTerm: searchTerm }),
|
|
129
|
-
' ')),
|
|
130
|
-
supportLevel: getFeatureSupportLevel('AMD_GPU'),
|
|
131
|
-
},
|
|
132
|
-
{
|
|
133
|
-
operatorKey: constants_1.OPERATOR_NAME_NVIDIA_GPU,
|
|
134
|
-
title: 'NVIDIA GPU',
|
|
135
|
-
featureId: 'NVIDIA_GPU',
|
|
136
|
-
descriptionText: operatorDescriptions_1.DESCRIPTION_NVIDIA_GPU,
|
|
137
|
-
Requirements: () => react_1.default.createElement(react_1.default.Fragment, null, "Requires at least one supported NVIDIA GPU"),
|
|
138
|
-
Description: ({ openshiftVersion, searchTerm }) => (react_1.default.createElement(react_1.default.Fragment, null,
|
|
139
|
-
react_1.default.createElement(exports.HighlightedText, { text: operatorDescriptions_1.DESCRIPTION_NVIDIA_GPU, searchTerm: searchTerm }),
|
|
140
|
-
' ',
|
|
141
|
-
react_1.default.createElement(ui_1.ExternalLink, { href: (0, config_1.getNvidiaGpuLink)(openshiftVersion) }, "Learn more"))),
|
|
142
|
-
supportLevel: getFeatureSupportLevel('NVIDIA_GPU'),
|
|
143
|
-
},
|
|
144
|
-
],
|
|
145
|
-
[exports.categories[Category.NETWORK]]: [
|
|
146
|
-
{
|
|
147
|
-
operatorKey: constants_1.OPERATOR_NAME_NMSTATE,
|
|
148
|
-
title: 'NMState',
|
|
149
|
-
featureId: 'NMSTATE',
|
|
150
|
-
descriptionText: operatorDescriptions_1.DESCRIPTION_NMSTATE,
|
|
151
|
-
Description: ({ openshiftVersion, searchTerm }) => (react_1.default.createElement(react_1.default.Fragment, null,
|
|
152
|
-
react_1.default.createElement(exports.HighlightedText, { text: operatorDescriptions_1.DESCRIPTION_NMSTATE, searchTerm: searchTerm }),
|
|
153
|
-
' ',
|
|
154
|
-
react_1.default.createElement(ui_1.ExternalLink, { href: (0, config_1.getNmstateLink)(openshiftVersion) }, "Learn more"))),
|
|
155
|
-
supportLevel: getFeatureSupportLevel('NMSTATE'),
|
|
156
|
-
},
|
|
157
|
-
{
|
|
158
|
-
operatorKey: constants_1.OPERATOR_NAME_SERVICEMESH,
|
|
159
|
-
title: 'Service Mesh',
|
|
160
|
-
featureId: 'SERVICEMESH',
|
|
161
|
-
descriptionText: operatorDescriptions_1.DESCRIPTION_SERVICEMESH,
|
|
162
|
-
Description: ({ openshiftVersion, searchTerm }) => (react_1.default.createElement(react_1.default.Fragment, null,
|
|
163
|
-
react_1.default.createElement(exports.HighlightedText, { text: operatorDescriptions_1.DESCRIPTION_SERVICEMESH, searchTerm: searchTerm }),
|
|
164
|
-
' ',
|
|
165
|
-
react_1.default.createElement(ui_1.ExternalLink, { href: (0, config_1.getServiceMeshLink)(openshiftVersion) }, "Learn more"))),
|
|
166
|
-
notStandalone: true,
|
|
167
|
-
supportLevel: getFeatureSupportLevel('SERVICEMESH'),
|
|
168
|
-
},
|
|
169
|
-
],
|
|
170
|
-
[exports.categories[Category.SECURITY]]: [
|
|
171
|
-
{
|
|
172
|
-
operatorKey: constants_1.OPERATOR_NAME_AUTHORINO,
|
|
173
|
-
title: 'Authorino',
|
|
174
|
-
featureId: 'AUTHORINO',
|
|
175
|
-
descriptionText: operatorDescriptions_1.DESCRIPTION_AUTHORINO,
|
|
176
|
-
Description: ({ searchTerm }) => (react_1.default.createElement(react_1.default.Fragment, null,
|
|
177
|
-
react_1.default.createElement(exports.HighlightedText, { text: operatorDescriptions_1.DESCRIPTION_AUTHORINO, searchTerm: searchTerm }),
|
|
178
|
-
' ',
|
|
179
|
-
react_1.default.createElement(ui_1.ExternalLink, { href: config_1.AUTHORINO_OPERATOR_LINK }, "Learn more"))),
|
|
180
|
-
notStandalone: true,
|
|
181
|
-
supportLevel: getFeatureSupportLevel('AUTHORINO'),
|
|
182
|
-
},
|
|
183
|
-
{
|
|
184
|
-
operatorKey: constants_1.OPERATOR_NAME_KMM,
|
|
185
|
-
title: 'Kernel Module Management',
|
|
186
|
-
featureId: 'KMM',
|
|
187
|
-
descriptionText: operatorDescriptions_1.DESCRIPTION_KMM,
|
|
188
|
-
Description: ({ openshiftVersion, searchTerm }) => (react_1.default.createElement(react_1.default.Fragment, null,
|
|
189
|
-
react_1.default.createElement(exports.HighlightedText, { text: operatorDescriptions_1.DESCRIPTION_KMM, searchTerm: searchTerm }),
|
|
190
|
-
' ',
|
|
191
|
-
react_1.default.createElement(ui_1.ExternalLink, { href: (0, config_1.getKmmDocsLink)(openshiftVersion) }, "Learn more"))),
|
|
192
|
-
supportLevel: getFeatureSupportLevel('KMM'),
|
|
193
|
-
},
|
|
194
|
-
],
|
|
195
|
-
[exports.categories[Category.CI_CD]]: [
|
|
196
|
-
{
|
|
197
|
-
operatorKey: constants_1.OPERATOR_NAME_PIPELINES,
|
|
198
|
-
title: 'Pipelines',
|
|
199
|
-
featureId: 'PIPELINES',
|
|
200
|
-
descriptionText: operatorDescriptions_1.DESCRIPTION_PIPELINES,
|
|
201
|
-
Description: ({ searchTerm }) => (react_1.default.createElement(react_1.default.Fragment, null,
|
|
202
|
-
react_1.default.createElement(exports.HighlightedText, { text: operatorDescriptions_1.DESCRIPTION_PIPELINES, searchTerm: searchTerm }),
|
|
203
|
-
' ',
|
|
204
|
-
react_1.default.createElement(ui_1.ExternalLink, { href: config_1.PIPELINES_OPERATOR_LINK }, "Learn more"))),
|
|
205
|
-
notStandalone: true,
|
|
206
|
-
supportLevel: getFeatureSupportLevel('PIPELINES'),
|
|
207
|
-
},
|
|
208
|
-
{
|
|
209
|
-
operatorKey: constants_1.OPERATOR_NAME_SERVERLESS,
|
|
210
|
-
title: 'Serverless',
|
|
211
|
-
featureId: 'SERVERLESS',
|
|
212
|
-
descriptionText: operatorDescriptions_1.DESCRIPTION_SERVERLESS,
|
|
213
|
-
Description: ({ searchTerm }) => (react_1.default.createElement(react_1.default.Fragment, null,
|
|
214
|
-
react_1.default.createElement(exports.HighlightedText, { text: operatorDescriptions_1.DESCRIPTION_SERVERLESS, searchTerm: searchTerm }),
|
|
215
|
-
' ',
|
|
216
|
-
react_1.default.createElement(ui_1.ExternalLink, { href: config_1.SERVERLESS_OPERATOR_LINK }, "Learn more"))),
|
|
217
|
-
notStandalone: true,
|
|
218
|
-
supportLevel: getFeatureSupportLevel('SERVERLESS'),
|
|
219
|
-
},
|
|
220
|
-
],
|
|
221
|
-
[exports.categories[Category.PLATFORM]]: [
|
|
222
|
-
{
|
|
223
|
-
operatorKey: constants_1.OPERATOR_NAME_MCE,
|
|
224
|
-
title: 'Multicluster engine',
|
|
225
|
-
featureId: 'MCE',
|
|
226
|
-
descriptionText: operatorDescriptions_1.DESCRIPTION_MCE,
|
|
227
|
-
Description: ({ openshiftVersion, searchTerm }) => (react_1.default.createElement(react_1.default.Fragment, null,
|
|
228
|
-
react_1.default.createElement(exports.HighlightedText, { text: operatorDescriptions_1.DESCRIPTION_MCE, searchTerm: searchTerm }),
|
|
229
|
-
' ',
|
|
230
|
-
react_1.default.createElement(ui_1.ExternalLink, { href: (0, config_1.getMceDocsLink)(openshiftVersion) }, "Learn more"))),
|
|
231
|
-
supportLevel: getFeatureSupportLevel('MCE'),
|
|
232
|
-
},
|
|
233
|
-
{
|
|
234
|
-
operatorKey: constants_1.OPERATOR_NAME_NODE_MAINTENANCE,
|
|
235
|
-
title: 'Node Maintenance',
|
|
236
|
-
featureId: 'NODE_MAINTENANCE',
|
|
237
|
-
descriptionText: operatorDescriptions_1.DESCRIPTION_NODE_MAINTENANCE,
|
|
238
|
-
Description: () => (react_1.default.createElement(react_1.default.Fragment, null,
|
|
239
|
-
operatorDescriptions_1.DESCRIPTION_NODE_MAINTENANCE,
|
|
240
|
-
' ',
|
|
241
|
-
react_1.default.createElement(ui_1.ExternalLink, { href: config_1.NODE_MAINTENANCE_LINK }, "Learn more"))),
|
|
242
|
-
notStandalone: true,
|
|
243
|
-
supportLevel: getFeatureSupportLevel('NODE_MAINTENANCE'),
|
|
244
|
-
},
|
|
245
|
-
],
|
|
246
|
-
[exports.categories[Category.SCHEDULING]]: [
|
|
247
|
-
{
|
|
248
|
-
operatorKey: constants_1.OPERATOR_NAME_NODE_FEATURE_DISCOVERY,
|
|
249
|
-
title: 'Node Feature Discovery',
|
|
250
|
-
featureId: 'NODE_FEATURE_DISCOVERY',
|
|
251
|
-
descriptionText: operatorDescriptions_1.DESCRIPTION_NODE_FEATURE_DISCOVERY,
|
|
252
|
-
Description: ({ openshiftVersion }) => (react_1.default.createElement(react_1.default.Fragment, null,
|
|
253
|
-
operatorDescriptions_1.DESCRIPTION_NODE_FEATURE_DISCOVERY,
|
|
254
|
-
' ',
|
|
255
|
-
react_1.default.createElement(ui_1.ExternalLink, { href: (0, config_1.getNodeFeatureDiscoveryLink)(openshiftVersion) }, "Learn more"))),
|
|
256
|
-
supportLevel: getFeatureSupportLevel('NODE_FEATURE_DISCOVERY'),
|
|
257
|
-
},
|
|
258
|
-
{
|
|
259
|
-
operatorKey: constants_1.OPERATOR_NAME_KUBE_DESCHEDULER,
|
|
260
|
-
title: 'Kube Descheduler',
|
|
261
|
-
featureId: 'KUBE_DESCHEDULER',
|
|
262
|
-
descriptionText: operatorDescriptions_1.DESCRIPTION_KUBE_DESCHEDULER,
|
|
263
|
-
Description: ({ openshiftVersion, searchTerm }) => (react_1.default.createElement(react_1.default.Fragment, null,
|
|
264
|
-
react_1.default.createElement(exports.HighlightedText, { text: operatorDescriptions_1.DESCRIPTION_KUBE_DESCHEDULER, searchTerm: searchTerm }),
|
|
265
|
-
' ',
|
|
266
|
-
react_1.default.createElement(ui_1.ExternalLink, { href: (0, config_1.getKubeDeschedulerLink)(openshiftVersion) }, "Learn more"))),
|
|
267
|
-
notStandalone: true,
|
|
268
|
-
supportLevel: getFeatureSupportLevel('KUBE_DESCHEDULER'),
|
|
269
|
-
},
|
|
270
|
-
],
|
|
271
|
-
};
|
|
272
|
-
};
|
|
273
|
-
exports.getOperatorSpecs = getOperatorSpecs;
|
|
274
|
-
const useOperatorSpecs = () => {
|
|
275
|
-
const { getFeatureSupportLevel } = (0, newFeatureSupportLevels_1.useNewFeatureSupportLevel)();
|
|
276
|
-
const useLVMS = getFeatureSupportLevel('LVM') === 'supported';
|
|
277
|
-
// Grouped by category
|
|
278
|
-
const byCategory = react_1.default.useMemo(() => (0, exports.getOperatorSpecs)(getFeatureSupportLevel, useLVMS), [getFeatureSupportLevel, useLVMS]);
|
|
279
|
-
// Flat map operatorKey -> spec
|
|
280
|
-
const byKey = react_1.default.useMemo(() => {
|
|
281
|
-
return Object.values(byCategory).reduce((acc, specs) => {
|
|
282
|
-
specs.forEach((spec) => {
|
|
283
|
-
acc[spec.operatorKey] = spec;
|
|
284
|
-
});
|
|
285
|
-
return acc;
|
|
286
|
-
}, {});
|
|
287
|
-
}, [byCategory]);
|
|
288
|
-
return { byCategory, byKey };
|
|
289
|
-
};
|
|
290
|
-
exports.useOperatorSpecs = useOperatorSpecs;
|
|
291
|
-
const getOperatorTitleByFeatureId = (featureId) => {
|
|
292
|
-
const allSpecs = (0, exports.getOperatorSpecs)(() => undefined);
|
|
293
|
-
for (const categorySpecs of Object.values(allSpecs)) {
|
|
294
|
-
const spec = categorySpecs.find((s) => s.featureId === featureId);
|
|
295
|
-
if (spec) {
|
|
296
|
-
return spec.title;
|
|
297
|
-
}
|
|
298
|
-
}
|
|
299
|
-
return undefined;
|
|
300
|
-
};
|
|
301
|
-
exports.getOperatorTitleByFeatureId = getOperatorTitleByFeatureId;
|
|
302
|
-
var Category;
|
|
303
|
-
(function (Category) {
|
|
304
|
-
Category[Category["STORAGE"] = 0] = "STORAGE";
|
|
305
|
-
Category[Category["VIRT"] = 1] = "VIRT";
|
|
306
|
-
Category[Category["AI"] = 2] = "AI";
|
|
307
|
-
Category[Category["NETWORK"] = 3] = "NETWORK";
|
|
308
|
-
Category[Category["CI_CD"] = 4] = "CI_CD";
|
|
309
|
-
Category[Category["PLATFORM"] = 5] = "PLATFORM";
|
|
310
|
-
Category[Category["SECURITY"] = 6] = "SECURITY";
|
|
311
|
-
Category[Category["SCHEDULING"] = 7] = "SCHEDULING";
|
|
312
|
-
})(Category || (Category = {}));
|
|
313
|
-
exports.categories = {
|
|
314
|
-
[Category.STORAGE]: 'Storage',
|
|
315
|
-
[Category.VIRT]: 'Virtualization',
|
|
316
|
-
[Category.AI]: 'AI',
|
|
317
|
-
[Category.NETWORK]: 'Network',
|
|
318
|
-
[Category.SECURITY]: 'Security & Access Control',
|
|
319
|
-
[Category.CI_CD]: 'CI/CD & Dev Productivity',
|
|
320
|
-
[Category.PLATFORM]: 'Platform Operations & Lifecycle',
|
|
321
|
-
[Category.SCHEDULING]: 'Scheduling',
|
|
322
|
-
};
|
|
323
|
-
//# sourceMappingURL=test.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"test.js","sourceRoot":"","sources":["../../../../../lib/common/components/operators/test.tsx"],"names":[],"mappings":";;;;AAAA,0DAA0B;AAG1B,sDAoBgC;AAChC,8BAAqC;AACrC,yCAsBsB;AACtB,uCAAmD;AACnD,wEAA+F;AAC/F,iEAoBgC;AAEhC,kGAAkG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
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const tslib_1 = require("tslib");
|
|
4
|
-
const React = tslib_1.__importStar(require("react"));
|
|
5
|
-
const formik_1 = require("formik");
|
|
6
|
-
const react_core_1 = require("@patternfly/react-core");
|
|
7
|
-
const utils_1 = require("./utils");
|
|
8
|
-
const featureSupportLevels_1 = require("../../featureSupportLevels");
|
|
9
|
-
const use_translation_wrapper_1 = require("../../../hooks/use-translation-wrapper");
|
|
10
|
-
const SingleNodeCheckbox = (_a) => {
|
|
11
|
-
var { versions, validate, idPostfix } = _a, props = tslib_1.__rest(_a, ["versions", "validate", "idPostfix"]);
|
|
12
|
-
const { values: { openshiftVersion }, } = (0, formik_1.useFormikContext)();
|
|
13
|
-
const [field, meta, helpers] = (0, formik_1.useField)({ name: props.name, validate });
|
|
14
|
-
const featureSupportLevelContext = (0, featureSupportLevels_1.useFeatureSupportLevel)();
|
|
15
|
-
const prevVersionRef = React.useRef(openshiftVersion);
|
|
16
|
-
const fieldId = (0, utils_1.getFieldId)(props.name, 'input', idPostfix);
|
|
17
|
-
const { t } = (0, use_translation_wrapper_1.useTranslation)();
|
|
18
|
-
const { value } = meta;
|
|
19
|
-
const { setValue } = helpers;
|
|
20
|
-
const isSupportedVersionAvailable = !!versions.find((version) => featureSupportLevelContext.isFeatureSupported(version.value, 'SNO'));
|
|
21
|
-
const onChanged = React.useCallback((checked) => setValue(checked ? 'None' : 'Full'), [setValue]);
|
|
22
|
-
const disabledReason = featureSupportLevelContext.getFeatureDisabledReason(openshiftVersion, 'SNO', t);
|
|
23
|
-
React.useEffect(() => {
|
|
24
|
-
if (prevVersionRef.current !== openshiftVersion &&
|
|
25
|
-
!featureSupportLevelContext.isFeatureSupported(openshiftVersion, 'SNO')) {
|
|
26
|
-
//invoke updating SNO value only if the version changed to not be in danger of touching existing clusters
|
|
27
|
-
onChanged(false);
|
|
28
|
-
}
|
|
29
|
-
prevVersionRef.current = openshiftVersion;
|
|
30
|
-
}, [openshiftVersion, onChanged, featureSupportLevelContext]);
|
|
31
|
-
if (isSupportedVersionAvailable) {
|
|
32
|
-
return (React.createElement(react_core_1.FormGroup, { isInline: true, fieldId: fieldId },
|
|
33
|
-
React.createElement(react_core_1.Tooltip, { hidden: !disabledReason, content: disabledReason },
|
|
34
|
-
React.createElement(react_core_1.Checkbox, Object.assign({}, field, props, { id: fieldId, label: React.createElement(React.Fragment, null,
|
|
35
|
-
t('ai:Install single node OpenShift (SNO)'),
|
|
36
|
-
"\u00A0",
|
|
37
|
-
React.createElement(featureSupportLevels_1.FeatureSupportLevelBadge, { featureId: "SNO", openshiftVersion: openshiftVersion })), "aria-describedby": `${fieldId}-helper`, description: React.createElement(react_core_1.FormGroup, null,
|
|
38
|
-
React.createElement(react_core_1.FormHelperText, null,
|
|
39
|
-
React.createElement(react_core_1.HelperText, { id: fieldId },
|
|
40
|
-
React.createElement(react_core_1.HelperTextItem, null, t('ai:SNO enables you to install OpenShift using only one host.'))))), isChecked: value === 'None', onChange: (_event, value) => onChanged(value), className: "with-tooltip" })))));
|
|
41
|
-
}
|
|
42
|
-
return null;
|
|
43
|
-
};
|
|
44
|
-
exports.default = SingleNodeCheckbox;
|
|
45
|
-
//# sourceMappingURL=SingleNodeCheckbox.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"SingleNodeCheckbox.js","sourceRoot":"","sources":["../../../../../../lib/common/components/ui/formik/SingleNodeCheckbox.tsx"],"names":[],"mappings":";;;AAAA,qDAA+B;AAC/B,mCAAoD;AACpD,uDAOgC;AAEhC,mCAAqC;AAErC,qEAA8F;AAE9F,oFAAwE;AAIxE,MAAM,kBAAkB,GAAsC,CAAC,EAK9D,EAAE,EAAE;QAL0D,EAC7D,QAAQ,EACR,QAAQ,EACR,SAAS,OAEV,EADI,KAAK,sBAJqD,qCAK9D,CADS;IAER,MAAM,EACJ,MAAM,EAAE,EAAE,gBAAgB,EAAE,GAC7B,GAAG,IA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,cAAc,CAAC,OAAO,GAAG,gBAAgB,CAAC;IAC5C,CAAC,EAAE,CAAC,gBAAgB,EAAE,SAAS,EAAE,0BAA0B,CAAC,CAAC,CAAC;IAE9D,IAAI,2BAA2B,EAAE;QAC/B,OAAO,CACL,oBAAC,sBAAS,IAAC,QAAQ,QAAC,OAAO,EAAE,OAAO;YAClC,oBAAC,oBAAO,IAAC,MAAM,EAAE,CAAC,cAAc,EAAE,OAAO,EAAE,cAAc;gBACvD,oBAAC,qBAAQ,oBACH,KAAK,EACL,KAAK,IACT,EAAE,EAAE,OAAO,EACX,KAAK,EACH;wBACG,CAAC,CAAC,wCAAwC,CAAC;;wBAC5C,oBAAC,+CAAwB,IAAC,SAAS,EAAC,KAAK,EAAC,gBAAgB,EAAE,gBAAgB,GAAI,CAC/E,sBAEa,GAAG,OAAO,SAAS,EACrC,WAAW,EACT,oBAAC,sBAAS;wBACR,oBAAC,2BAAc;4BACb,oBAAC,uBAAU,IAAC,EAAE,EAAE,OAAO;gCACrB,oBAAC,2BAAc,QACZ,CAAC,CAAC,8DAA8D,CAAC,CACnD,CACN,CACE,CACP,EAEd,SAAS,EAAE,KAAK,KAAK,MAAM,EAC3B,QAAQ,EAAE,CAAC,MAAM,EAAE,KAAK,EAAE,EAAE,CAAC,SAAS,CAAC,KAAK,CAAC,EAC7C,SAAS,EAAC,cAAc,IACxB,CACM,CACA,CACb,CAAC;KACH;IACD,OAAO,IAAI,CAAC;AACd,CAAC,CAAC;AAEF,kBAAe,kBAAkB,CAAC"}
|
|
@@ -1,51 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const tslib_1 = require("tslib");
|
|
4
|
-
const React = tslib_1.__importStar(require("react"));
|
|
5
|
-
const formik_1 = require("formik");
|
|
6
|
-
const react_core_1 = require("@patternfly/react-core");
|
|
7
|
-
const common_1 = require("../../../common");
|
|
8
|
-
const newFeatureSupportLevels_1 = require("../../../common/components/newFeatureSupportLevels");
|
|
9
|
-
const NewFeatureSupportLevelBadge_1 = tslib_1.__importDefault(require("../../../common/components/newFeatureSupportLevels/NewFeatureSupportLevelBadge"));
|
|
10
|
-
const use_translation_wrapper_1 = require("../../../common/hooks/use-translation-wrapper");
|
|
11
|
-
const OcmSingleNodeCheckbox = (_a) => {
|
|
12
|
-
var { disabledReason, isSupportedVersionAvailable, validate, idPostfix, supportLevel } = _a, props = tslib_1.__rest(_a, ["disabledReason", "isSupportedVersionAvailable", "validate", "idPostfix", "supportLevel"]);
|
|
13
|
-
const { values: { openshiftVersion }, } = (0, formik_1.useFormikContext)();
|
|
14
|
-
const [field, meta, helpers] = (0, formik_1.useField)({ name: props.name, validate });
|
|
15
|
-
const featureSupportLevelContext = (0, newFeatureSupportLevels_1.useNewFeatureSupportLevel)();
|
|
16
|
-
const prevVersionRef = React.useRef(openshiftVersion);
|
|
17
|
-
const prevIsDisabled = React.useRef(props.isDisabled);
|
|
18
|
-
const fieldId = (0, common_1.getFieldId)(props.name, 'input', idPostfix);
|
|
19
|
-
const { t } = (0, use_translation_wrapper_1.useTranslation)();
|
|
20
|
-
const { value } = meta;
|
|
21
|
-
const { setValue } = helpers;
|
|
22
|
-
const onChanged = React.useCallback((checked) => setValue(checked ? 'None' : 'Full'), [setValue]);
|
|
23
|
-
React.useEffect(() => {
|
|
24
|
-
if (prevVersionRef.current !== openshiftVersion &&
|
|
25
|
-
!featureSupportLevelContext.isFeatureSupported('SNO')) {
|
|
26
|
-
//invoke updating SNO value only if the version changed to not be in danger of touching existing clusters
|
|
27
|
-
onChanged(false);
|
|
28
|
-
}
|
|
29
|
-
prevVersionRef.current = openshiftVersion;
|
|
30
|
-
}, [openshiftVersion, onChanged, featureSupportLevelContext]);
|
|
31
|
-
React.useEffect(() => {
|
|
32
|
-
if (prevIsDisabled.current !== props.isDisabled) {
|
|
33
|
-
onChanged(false);
|
|
34
|
-
}
|
|
35
|
-
prevIsDisabled.current = props.isDisabled;
|
|
36
|
-
}, [props.isDisabled, setValue, onChanged]);
|
|
37
|
-
if (isSupportedVersionAvailable) {
|
|
38
|
-
return (React.createElement(react_core_1.FormGroup, { id: `form-control__${fieldId}`, isInline: true, fieldId: fieldId },
|
|
39
|
-
React.createElement(react_core_1.Tooltip, { hidden: !disabledReason, content: disabledReason },
|
|
40
|
-
React.createElement(react_core_1.Checkbox, Object.assign({}, field, props, { id: fieldId, label: React.createElement(React.Fragment, null,
|
|
41
|
-
t('ai:Install single node OpenShift (SNO)'),
|
|
42
|
-
"\u00A0",
|
|
43
|
-
React.createElement(NewFeatureSupportLevelBadge_1.default, { featureId: "SNO", supportLevel: supportLevel })), "aria-describedby": `${fieldId}-helper`, description: React.createElement(react_core_1.FormGroup, null,
|
|
44
|
-
React.createElement(react_core_1.FormHelperText, null,
|
|
45
|
-
React.createElement(react_core_1.HelperText, { id: fieldId },
|
|
46
|
-
React.createElement(react_core_1.HelperTextItem, null, t('ai:SNO enables you to install OpenShift using only one host.'))))), isChecked: value === 'None', onChange: (event, value) => onChanged(value), className: "with-tooltip" })))));
|
|
47
|
-
}
|
|
48
|
-
return null;
|
|
49
|
-
};
|
|
50
|
-
exports.default = OcmSingleNodeCheckbox;
|
|
51
|
-
//# sourceMappingURL=OcmSingleNodeCheckbox.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"OcmSingleNodeCheckbox.js","sourceRoot":"","sources":["../../../../../lib/ocm/components/clusterConfiguration/OcmSingleNodeCheckbox.tsx"],"names":[],"mappings":";;;AAAA,qDAA+B;AAC/B,mCAAoD;AACpD,uDAOgC;AAChC,4CAA6C;AAC7C,gGAA+F;AAE/F,yJAAyH;AACzH,2FAA+E;AAY/E,MAAM,qBAAqB,GAA+B,CAAC,EAO1D,EAAE,EAAE;QAPsD,EACzD,cAAc,EACd,2BAA2B,EAC3B,QAAQ,EACR,SAAS,EACT,YAAY,OAEb,EADI,KAAK,sBANiD,0FAO1D,CADS;IAER,MAAM,EACJ,MAAM,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;QACnB,IAAI,cAAc,CAAC,OAAO,KAAK,KAAK,CAAC,UAAU,EAAE;YAC/C,SAAS,CAAC,KAAK,CAAC,CAAC;SAClB;QACD,cAAc,CAAC,OAAO,GAAG,KAAK,CAAC,UAAU,CAAC;IAC5C,CAAC,EAAE,CAAC,KAAK,CAAC,UAAU,EAAE,QAAQ,EAAE,SAAS,CAAC,CAAC,CAAC;IAE5C,IAAI,2BAA2B,EAAE;QAC/B,OAAO,CACL,oBAAC,sBAAS,IAAC,EAAE,EAAE,iBAAiB,OAAO,EAAE,EAAE,QAAQ,QAAC,OAAO,EAAE,OAAO;YAClE,oBAAC,oBAAO,IAAC,MAAM,EAAE,CAAC,cAAc,EAAE,OAAO,EAAE,cAAc;gBACvD,oBAAC,qBAAQ,oBACH,KAAK,EACL,KAAK,IACT,EAAE,EAAE,OAAO,EACX,KAAK,EACH;wBACG,CAAC,CAAC,wCAAwC,CAAC;;wBAC5C,oBAAC,qCAA2B,IAAC,SAAS,EAAC,KAAK,EAAC,YAAY,EAAE,YAAY,GAAI,CAC1E,sBAEa,GAAG,OAAO,SAAS,EACrC,WAAW,EACT,oBAAC,sBAAS;wBACR,oBAAC,2BAAc;4BACb,oBAAC,uBAAU,IAAC,EAAE,EAAE,OAAO;gCACrB,oBAAC,2BAAc,QACZ,CAAC,CAAC,8DAA8D,CAAC,CACnD,CACN,CACE,CACP,EAEd,SAAS,EAAE,KAAK,KAAK,MAAM,EAC3B,QAAQ,EAAE,CAAC,KAAK,EAAE,KAAK,EAAE,EAAE,CAAC,SAAS,CAAC,KAAK,CAAC,EAC5C,SAAS,EAAC,cAAc,IACxB,CACM,CACA,CACb,CAAC;KACH;IACD,OAAO,IAAI,CAAC;AACd,CAAC,CAAC;AAEF,kBAAe,qBAAqB,CAAC"}
|
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { useFormikContext } from 'formik';
|
|
3
|
-
import { ClusterDetailsValues } from '../../../common/components/clusterWizard/types';
|
|
4
|
-
import { SingleNodeCheckbox } from '../ui';
|
|
5
|
-
import { OpenshiftVersionOptionType } from '../../types';
|
|
6
|
-
import SNODisclaimer from './SNODisclaimer';
|
|
7
|
-
import { useFeatureSupportLevel } from '../featureSupportLevels';
|
|
8
|
-
|
|
9
|
-
type SNOControlGroupProps = {
|
|
10
|
-
versions: OpenshiftVersionOptionType[];
|
|
11
|
-
highAvailabilityMode: ClusterDetailsValues['highAvailabilityMode'];
|
|
12
|
-
};
|
|
13
|
-
|
|
14
|
-
const SNOControlGroup = ({ versions, highAvailabilityMode }: SNOControlGroupProps) => {
|
|
15
|
-
const { values } = useFormikContext<ClusterDetailsValues>();
|
|
16
|
-
const featureSupportLevelContext = useFeatureSupportLevel();
|
|
17
|
-
const snoSupportLevel = featureSupportLevelContext.getFeatureSupportLevel(
|
|
18
|
-
values.openshiftVersion,
|
|
19
|
-
'SNO',
|
|
20
|
-
);
|
|
21
|
-
const snoExpansion = featureSupportLevelContext.isFeatureSupported(
|
|
22
|
-
values.openshiftVersion,
|
|
23
|
-
'SINGLE_NODE_EXPANSION',
|
|
24
|
-
);
|
|
25
|
-
const isDisabled = featureSupportLevelContext.isFeatureDisabled(values.openshiftVersion, 'SNO');
|
|
26
|
-
|
|
27
|
-
return (
|
|
28
|
-
<>
|
|
29
|
-
<SingleNodeCheckbox name="highAvailabilityMode" versions={versions} isDisabled={isDisabled} />
|
|
30
|
-
{highAvailabilityMode === 'None' && snoSupportLevel && (
|
|
31
|
-
<SNODisclaimer
|
|
32
|
-
isDisabled={isDisabled}
|
|
33
|
-
snoSupportLevel={snoSupportLevel}
|
|
34
|
-
snoExpansionSupported={snoExpansion}
|
|
35
|
-
/>
|
|
36
|
-
)}
|
|
37
|
-
</>
|
|
38
|
-
);
|
|
39
|
-
};
|
|
40
|
-
|
|
41
|
-
export default SNOControlGroup;
|
|
@@ -1,79 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { Alert, AlertVariant, List, ListItem, Stack, StackItem } from '@patternfly/react-core';
|
|
3
|
-
import { CheckboxField } from '../ui';
|
|
4
|
-
import { useTranslation } from '../../hooks/use-translation-wrapper';
|
|
5
|
-
import { SupportLevel } from '@openshift-assisted/types/assisted-installer-service';
|
|
6
|
-
|
|
7
|
-
type SNODisclaimerProps = {
|
|
8
|
-
snoSupportLevel: SupportLevel;
|
|
9
|
-
isDisabled?: boolean;
|
|
10
|
-
snoExpansionSupported?: boolean;
|
|
11
|
-
};
|
|
12
|
-
const SNODisclaimer = ({
|
|
13
|
-
snoSupportLevel,
|
|
14
|
-
isDisabled = false,
|
|
15
|
-
snoExpansionSupported = false,
|
|
16
|
-
}: SNODisclaimerProps) => {
|
|
17
|
-
const { t } = useTranslation();
|
|
18
|
-
if (!['dev-preview', 'supported'].includes(snoSupportLevel)) {
|
|
19
|
-
//if tech preview or unsupported there's no definition which warning to show
|
|
20
|
-
return null;
|
|
21
|
-
}
|
|
22
|
-
const isDevPreview = snoSupportLevel === 'dev-preview';
|
|
23
|
-
const generalSNOFacts = (
|
|
24
|
-
<>
|
|
25
|
-
<ListItem>
|
|
26
|
-
{t(
|
|
27
|
-
'ai:Installing SNO will result in an OpenShift deployment that is not highly available.',
|
|
28
|
-
)}
|
|
29
|
-
</ListItem>
|
|
30
|
-
{!snoExpansionSupported && (
|
|
31
|
-
<ListItem>
|
|
32
|
-
{t('ai:Currently, adding additional machines to your cluster is not supported.')}
|
|
33
|
-
</ListItem>
|
|
34
|
-
)}
|
|
35
|
-
</>
|
|
36
|
-
);
|
|
37
|
-
const unsupportedWarnings = (
|
|
38
|
-
<>
|
|
39
|
-
<ListItem>
|
|
40
|
-
{t('ai:SNO is in a proof-of-concept stage and is not supported in any way.')}
|
|
41
|
-
</ListItem>
|
|
42
|
-
<ListItem>
|
|
43
|
-
{t(
|
|
44
|
-
"ai:OpenShift in-place upgrades aren't expected to work with SNO. If an upgrade is needed, your system will need a redeployment.",
|
|
45
|
-
)}
|
|
46
|
-
</ListItem>
|
|
47
|
-
</>
|
|
48
|
-
);
|
|
49
|
-
|
|
50
|
-
return (
|
|
51
|
-
<Alert
|
|
52
|
-
variant={isDevPreview ? AlertVariant.warning : AlertVariant.info}
|
|
53
|
-
title={t('ai:Limitations for using Single Node OpenShift')}
|
|
54
|
-
isInline
|
|
55
|
-
>
|
|
56
|
-
<Stack hasGutter>
|
|
57
|
-
<StackItem>
|
|
58
|
-
<List>
|
|
59
|
-
{generalSNOFacts}
|
|
60
|
-
{isDevPreview && unsupportedWarnings}
|
|
61
|
-
</List>
|
|
62
|
-
</StackItem>
|
|
63
|
-
{isDevPreview && (
|
|
64
|
-
<StackItem>
|
|
65
|
-
<CheckboxField
|
|
66
|
-
name="SNODisclaimer"
|
|
67
|
-
label={t(
|
|
68
|
-
'ai:I understand, accept, and agree to the limitations associated with using Single Node OpenShift.',
|
|
69
|
-
)}
|
|
70
|
-
isDisabled={isDisabled}
|
|
71
|
-
/>
|
|
72
|
-
</StackItem>
|
|
73
|
-
)}
|
|
74
|
-
</Stack>
|
|
75
|
-
</Alert>
|
|
76
|
-
);
|
|
77
|
-
};
|
|
78
|
-
|
|
79
|
-
export default SNODisclaimer;
|