diff --git a/charts/kubedbcom-cassandra-editor-options/ui/create-ui.yaml b/charts/kubedbcom-cassandra-editor-options/ui/create-ui.yaml index 1c47938969..4fef7d3c38 100644 --- a/charts/kubedbcom-cassandra-editor-options/ui/create-ui.yaml +++ b/charts/kubedbcom-cassandra-editor-options/ui/create-ui.yaml @@ -273,6 +273,9 @@ step: - LoadBalancer schema: svcType type: select + init: + type: func + value: setServiceTemplate label: New Service Template schema: schema/properties/spec/properties/serviceTemplates type: array-object-form diff --git a/charts/kubedbcom-cassandra-editor-options/ui/functions.js b/charts/kubedbcom-cassandra-editor-options/ui/functions.js index 4531ecbff3..762e05133b 100644 --- a/charts/kubedbcom-cassandra-editor-options/ui/functions.js +++ b/charts/kubedbcom-cassandra-editor-options/ui/functions.js @@ -1067,6 +1067,10 @@ export const useFunc = (model) => { } } + function setServiceTemplate() { + const serviceTemplates = getValue(model, '/spec/admin/serviceTemplates') || [] + if (serviceTemplates.length) return serviceTemplates + } return { onReferSecretChange, showReferSecretSwitch, @@ -1108,5 +1112,6 @@ export const useFunc = (model) => { setBackup, getDefault, validateRackName, + setServiceTemplate, } } diff --git a/charts/kubedbcom-clickhouse-editor-options/ui/create-ui.yaml b/charts/kubedbcom-clickhouse-editor-options/ui/create-ui.yaml index 99a31bc61e..9ff77ddcee 100644 --- a/charts/kubedbcom-clickhouse-editor-options/ui/create-ui.yaml +++ b/charts/kubedbcom-clickhouse-editor-options/ui/create-ui.yaml @@ -423,6 +423,9 @@ step: - LoadBalancer schema: svcType type: select + init: + type: func + value: setServiceTemplate label: New Service Template schema: schema/properties/spec/properties/serviceTemplates type: array-object-form diff --git a/charts/kubedbcom-clickhouse-editor-options/ui/functions.js b/charts/kubedbcom-clickhouse-editor-options/ui/functions.js index a01d28c697..fff0207b82 100644 --- a/charts/kubedbcom-clickhouse-editor-options/ui/functions.js +++ b/charts/kubedbcom-clickhouse-editor-options/ui/functions.js @@ -1143,6 +1143,10 @@ export const useFunc = (model) => { } } + function setServiceTemplate() { + const serviceTemplates = getValue(model, '/spec/admin/serviceTemplates') || [] + if (serviceTemplates.length) return serviceTemplates + } return { isExternallyManaged, showReferSecretSwitch, @@ -1186,5 +1190,6 @@ export const useFunc = (model) => { setPointInTimeRecovery, onTimestampChange, showRecovery, + setServiceTemplate, } } diff --git a/charts/kubedbcom-db2-editor-options/ui/create-ui.yaml b/charts/kubedbcom-db2-editor-options/ui/create-ui.yaml index 360b024f1a..1a6f1c68f7 100644 --- a/charts/kubedbcom-db2-editor-options/ui/create-ui.yaml +++ b/charts/kubedbcom-db2-editor-options/ui/create-ui.yaml @@ -257,6 +257,9 @@ step: - LoadBalancer schema: svcType type: select + init: + type: func + value: setServiceTemplate label: New Service Template schema: schema/properties/spec/properties/serviceTemplates type: array-object-form diff --git a/charts/kubedbcom-db2-editor-options/ui/functions.js b/charts/kubedbcom-db2-editor-options/ui/functions.js index bc6faa4a6e..ddcd030599 100644 --- a/charts/kubedbcom-db2-editor-options/ui/functions.js +++ b/charts/kubedbcom-db2-editor-options/ui/functions.js @@ -956,6 +956,10 @@ export const useFunc = (model) => { }) } + function setServiceTemplate() { + const serviceTemplates = getValue(model, '/spec/admin/serviceTemplates') || [] + if (serviceTemplates.length) return serviceTemplates + } return { showReferSecretSwitch, onReferSecretChange, @@ -988,5 +992,6 @@ export const useFunc = (model) => { showSelectZone, setStorageClass, getDefault, + setServiceTemplate, } } diff --git a/charts/kubedbcom-documentdb-editor-options/ui/create-ui.yaml b/charts/kubedbcom-documentdb-editor-options/ui/create-ui.yaml index 15009e44ed..3eea5785d0 100644 --- a/charts/kubedbcom-documentdb-editor-options/ui/create-ui.yaml +++ b/charts/kubedbcom-documentdb-editor-options/ui/create-ui.yaml @@ -303,6 +303,9 @@ step: - LoadBalancer schema: svcType type: select + init: + type: func + value: setServiceTemplate label: New Service Template schema: schema/properties/spec/properties/serviceTemplates type: array-object-form diff --git a/charts/kubedbcom-documentdb-editor-options/ui/functions.js b/charts/kubedbcom-documentdb-editor-options/ui/functions.js index fa6bebf5f5..23e7da6203 100644 --- a/charts/kubedbcom-documentdb-editor-options/ui/functions.js +++ b/charts/kubedbcom-documentdb-editor-options/ui/functions.js @@ -1221,6 +1221,10 @@ export const useFunc = (model) => { } } + function setServiceTemplate() { + const serviceTemplates = getValue(model, '/spec/admin/serviceTemplates') || [] + if (serviceTemplates.length) return serviceTemplates + } return { onReferSecretChange, showReferSecretSwitch, @@ -1261,5 +1265,6 @@ export const useFunc = (model) => { showArchiverAlert, showArchiver, onTimestampChange, + setServiceTemplate, } } diff --git a/charts/kubedbcom-druid-editor-options/ui/create-ui.yaml b/charts/kubedbcom-druid-editor-options/ui/create-ui.yaml index e83586b815..09bb49bc7d 100644 --- a/charts/kubedbcom-druid-editor-options/ui/create-ui.yaml +++ b/charts/kubedbcom-druid-editor-options/ui/create-ui.yaml @@ -545,6 +545,9 @@ step: - LoadBalancer schema: svcType type: select + init: + type: func + value: setServiceTemplate label: New Service Template schema: schema/properties/spec/properties/serviceTemplates type: array-object-form diff --git a/charts/kubedbcom-druid-editor-options/ui/functions.js b/charts/kubedbcom-druid-editor-options/ui/functions.js index 13d64ca640..8fd91ba26f 100644 --- a/charts/kubedbcom-druid-editor-options/ui/functions.js +++ b/charts/kubedbcom-druid-editor-options/ui/functions.js @@ -1074,6 +1074,10 @@ export const useFunc = (model) => { }) } + function setServiceTemplate() { + const serviceTemplates = getValue(model, '/spec/admin/serviceTemplates') || [] + if (serviceTemplates.length) return serviceTemplates + } return { showReferSecretSwitch, onReferSecretChange, @@ -1111,5 +1115,6 @@ export const useFunc = (model) => { getAdminOptions, setBackup, getDefault, + setServiceTemplate, } } diff --git a/charts/kubedbcom-elasticsearch-editor-options/ui/create-ui.yaml b/charts/kubedbcom-elasticsearch-editor-options/ui/create-ui.yaml index 4ca7dfdacc..fed266caf5 100644 --- a/charts/kubedbcom-elasticsearch-editor-options/ui/create-ui.yaml +++ b/charts/kubedbcom-elasticsearch-editor-options/ui/create-ui.yaml @@ -446,6 +446,9 @@ step: - LoadBalancer schema: svcType type: select + init: + type: func + value: setServiceTemplate label: New Service Template schema: schema/properties/spec/properties/serviceTemplates type: array-object-form diff --git a/charts/kubedbcom-elasticsearch-editor-options/ui/functions.js b/charts/kubedbcom-elasticsearch-editor-options/ui/functions.js index 9b1ed175e4..963d0f980a 100644 --- a/charts/kubedbcom-elasticsearch-editor-options/ui/functions.js +++ b/charts/kubedbcom-elasticsearch-editor-options/ui/functions.js @@ -1015,6 +1015,10 @@ export const useFunc = (model) => { }) } + function setServiceTemplate() { + const serviceTemplates = getValue(model, '/spec/admin/serviceTemplates') || [] + if (serviceTemplates.length) return serviceTemplates + } return { showReferSecretSwitch, onReferSecretChange, @@ -1054,5 +1058,6 @@ export const useFunc = (model) => { onBackupSwitch, setBackup, getDefault, + setServiceTemplate, } } diff --git a/charts/kubedbcom-hanadb-editor-options/ui/create-ui.yaml b/charts/kubedbcom-hanadb-editor-options/ui/create-ui.yaml index 276259c734..2039568fa4 100644 --- a/charts/kubedbcom-hanadb-editor-options/ui/create-ui.yaml +++ b/charts/kubedbcom-hanadb-editor-options/ui/create-ui.yaml @@ -293,6 +293,9 @@ step: - LoadBalancer schema: svcType type: select + init: + type: func + value: setServiceTemplate label: New Service Template schema: schema/properties/spec/properties/serviceTemplates type: array-object-form diff --git a/charts/kubedbcom-hanadb-editor-options/ui/functions.js b/charts/kubedbcom-hanadb-editor-options/ui/functions.js index 401ff86424..1fa37fec0b 100644 --- a/charts/kubedbcom-hanadb-editor-options/ui/functions.js +++ b/charts/kubedbcom-hanadb-editor-options/ui/functions.js @@ -1032,6 +1032,10 @@ export const useFunc = (model) => { return !!modelPathValue && showReferSecret() } + function setServiceTemplate() { + const serviceTemplates = getValue(model, '/spec/admin/serviceTemplates') || [] + if (serviceTemplates.length) return serviceTemplates + } return { onReferSecretChange, showReferSecretSwitch, @@ -1068,5 +1072,6 @@ export const useFunc = (model) => { isConfigDatabaseOn, clearConfiguration, getDefault, + setServiceTemplate, } } diff --git a/charts/kubedbcom-hazelcast-editor-options/ui/create-ui.yaml b/charts/kubedbcom-hazelcast-editor-options/ui/create-ui.yaml index cc8a55a23d..f9035ded28 100644 --- a/charts/kubedbcom-hazelcast-editor-options/ui/create-ui.yaml +++ b/charts/kubedbcom-hazelcast-editor-options/ui/create-ui.yaml @@ -254,6 +254,9 @@ step: - LoadBalancer schema: svcType type: select + init: + type: func + value: setServiceTemplate label: New Service Template schema: schema/properties/spec/properties/serviceTemplates type: array-object-form diff --git a/charts/kubedbcom-hazelcast-editor-options/ui/functions.js b/charts/kubedbcom-hazelcast-editor-options/ui/functions.js index 86ae713cc0..86fdb48d5d 100644 --- a/charts/kubedbcom-hazelcast-editor-options/ui/functions.js +++ b/charts/kubedbcom-hazelcast-editor-options/ui/functions.js @@ -1163,6 +1163,10 @@ export const useFunc = (model) => { } } + function setServiceTemplate() { + const serviceTemplates = getValue(model, '/spec/admin/serviceTemplates') || [] + if (serviceTemplates.length) return serviceTemplates + } return { getArchiverName, onArchiverChange, @@ -1207,5 +1211,6 @@ export const useFunc = (model) => { setBackup, showAdditionalSettings, getDefault, + setServiceTemplate, } } diff --git a/charts/kubedbcom-ignite-editor-options/ui/create-ui.yaml b/charts/kubedbcom-ignite-editor-options/ui/create-ui.yaml index a3b19743eb..f661d0543b 100644 --- a/charts/kubedbcom-ignite-editor-options/ui/create-ui.yaml +++ b/charts/kubedbcom-ignite-editor-options/ui/create-ui.yaml @@ -249,6 +249,9 @@ step: - LoadBalancer schema: svcType type: select + init: + type: func + value: setServiceTemplate label: New Service Template schema: schema/properties/spec/properties/serviceTemplates type: array-object-form diff --git a/charts/kubedbcom-ignite-editor-options/ui/functions.js b/charts/kubedbcom-ignite-editor-options/ui/functions.js index a520ef412f..3a9799ee2f 100644 --- a/charts/kubedbcom-ignite-editor-options/ui/functions.js +++ b/charts/kubedbcom-ignite-editor-options/ui/functions.js @@ -1042,6 +1042,10 @@ export const useFunc = (model) => { }) } + function setServiceTemplate() { + const serviceTemplates = getValue(model, '/spec/admin/serviceTemplates') || [] + if (serviceTemplates.length) return serviceTemplates + } return { showReferSecretSwitch, onReferSecretChange, @@ -1080,5 +1084,6 @@ export const useFunc = (model) => { setStorageClass, showAdditionalSettings, getDefault, + setServiceTemplate, } } diff --git a/charts/kubedbcom-kafka-editor-options/ui/create-ui.yaml b/charts/kubedbcom-kafka-editor-options/ui/create-ui.yaml index f416ad5c81..7279411101 100644 --- a/charts/kubedbcom-kafka-editor-options/ui/create-ui.yaml +++ b/charts/kubedbcom-kafka-editor-options/ui/create-ui.yaml @@ -376,6 +376,9 @@ step: - LoadBalancer schema: svcType type: select + init: + type: func + value: setServiceTemplate label: New Service Template schema: schema/properties/spec/properties/serviceTemplates type: array-object-form diff --git a/charts/kubedbcom-kafka-editor-options/ui/functions.js b/charts/kubedbcom-kafka-editor-options/ui/functions.js index 0383937ca5..afdbb40b65 100644 --- a/charts/kubedbcom-kafka-editor-options/ui/functions.js +++ b/charts/kubedbcom-kafka-editor-options/ui/functions.js @@ -962,6 +962,10 @@ export const useFunc = (model) => { }) } + function setServiceTemplate() { + const serviceTemplates = getValue(model, '/spec/admin/serviceTemplates') || [] + if (serviceTemplates.length) return serviceTemplates + } return { showReferSecretSwitch, onReferSecretChange, @@ -993,5 +997,6 @@ export const useFunc = (model) => { updateAlertValue, showAlerts, getDefault, + setServiceTemplate, } } diff --git a/charts/kubedbcom-mariadb-editor-options/ui/create-ui.yaml b/charts/kubedbcom-mariadb-editor-options/ui/create-ui.yaml index 76070e074e..6fc7e86722 100644 --- a/charts/kubedbcom-mariadb-editor-options/ui/create-ui.yaml +++ b/charts/kubedbcom-mariadb-editor-options/ui/create-ui.yaml @@ -32,6 +32,72 @@ step: label: Replicas schema: schema/properties/spec/properties/replicas type: input + - elements: + - label: "" + subtitle: Select a machine profile to allocate CPU and memory resources for + your database cluster. Choose 'custom' to manually specify resource requirements + or select a predefined profile. + type: label-element + - elements: + - init: + type: func + value: setMachineToCustom + label: Machine + loader: getMachineListForOptions + schema: schema/properties/spec/properties/podResources/properties/machine + type: select + - disable: + name: isMachineNotCustom + watchPaths: + - schema/properties/spec/properties/podResources/properties/machine + init: + type: func + value: setLimits|cpu + label: CPU + loader: setLimits|cpu + schema: schema/properties/spec/properties/podResources/properties/resources/properties/requests/properties/cpu + type: input + watcher: + func: setRequests|cpu + paths: + - schema/properties/spec/properties/podResources/properties/resources/properties/requests/properties/cpu + - schema/properties/spec/properties/podResources/properties/machine + - disable: + name: isMachineNotCustom + watchPaths: + - schema/properties/spec/properties/podResources/properties/machine + init: + type: func + value: setLimits|memory + label: Memory + loader: setLimits|memory + schema: schema/properties/spec/properties/podResources/properties/resources/properties/requests/properties/memory + type: input + watcher: + func: setRequests|memory + paths: + - schema/properties/spec/properties/podResources/properties/resources/properties/requests/properties/memory + - schema/properties/spec/properties/podResources/properties/machine + showLabels: true + type: horizontal-layout + label: Machine Profile + showLabels: true + type: block-layout + - elements: + - elements: + - if: + name: isToggleOn|storageClasses + type: function + label: Storage Class + loader: getAdminOptions|storageClasses + schema: schema/properties/spec/properties/admin/properties/storageClasses/properties/default + type: select + - label: Storage Size + schema: schema/properties/spec/properties/persistence/properties/size + type: input + showLabels: true + type: horizontal-layout + type: block-layout - elements: - label: "" subtitle: Configure the MaxScale proxy tier that fronts the MariaDB replication @@ -110,72 +176,6 @@ step: label: MaxScale showLabels: true type: block-layout - - elements: - - label: "" - subtitle: Select a machine profile to allocate CPU and memory resources for - your database cluster. Choose 'custom' to manually specify resource requirements - or select a predefined profile. - type: label-element - - elements: - - init: - type: func - value: setMachineToCustom - label: Machine - loader: getMachineListForOptions - schema: schema/properties/spec/properties/podResources/properties/machine - type: select - - disable: - name: isMachineNotCustom - watchPaths: - - schema/properties/spec/properties/podResources/properties/machine - init: - type: func - value: setLimits|cpu - label: CPU - loader: setLimits|cpu - schema: schema/properties/spec/properties/podResources/properties/resources/properties/requests/properties/cpu - type: input - watcher: - func: setRequests|cpu - paths: - - schema/properties/spec/properties/podResources/properties/resources/properties/requests/properties/cpu - - schema/properties/spec/properties/podResources/properties/machine - - disable: - name: isMachineNotCustom - watchPaths: - - schema/properties/spec/properties/podResources/properties/machine - init: - type: func - value: setLimits|memory - label: Memory - loader: setLimits|memory - schema: schema/properties/spec/properties/podResources/properties/resources/properties/requests/properties/memory - type: input - watcher: - func: setRequests|memory - paths: - - schema/properties/spec/properties/podResources/properties/resources/properties/requests/properties/memory - - schema/properties/spec/properties/podResources/properties/machine - showLabels: true - type: horizontal-layout - label: Machine Profile - showLabels: true - type: block-layout - - elements: - - elements: - - if: - name: isToggleOn|storageClasses - type: function - label: Storage Class - loader: getAdminOptions|storageClasses - schema: schema/properties/spec/properties/admin/properties/storageClasses/properties/default - type: select - - label: Storage Size - schema: schema/properties/spec/properties/persistence/properties/size - type: input - showLabels: true - type: horizontal-layout - type: block-layout - description: Configure Credentials, Deployment Mode etc. elements: - elements: @@ -385,6 +385,9 @@ step: - LoadBalancer schema: svcType type: select + init: + type: func + value: setServiceTemplate label: New Service Template schema: schema/properties/spec/properties/serviceTemplates type: array-object-form diff --git a/charts/kubedbcom-mariadb-editor-options/ui/functions.js b/charts/kubedbcom-mariadb-editor-options/ui/functions.js index 161758c687..c20b886391 100644 --- a/charts/kubedbcom-mariadb-editor-options/ui/functions.js +++ b/charts/kubedbcom-mariadb-editor-options/ui/functions.js @@ -1301,6 +1301,10 @@ export const useFunc = (model) => { return !!modelPathValue && showReferSecret() } + function setServiceTemplate() { + const serviceTemplates = getValue(model, '/spec/admin/serviceTemplates') || [] + if (serviceTemplates.length) return serviceTemplates + } return { onReferSecretChange, showReferSecretSwitch, @@ -1350,5 +1354,6 @@ export const useFunc = (model) => { showArchiverAlert, showArchiver, onTimestampChange, + setServiceTemplate, } } diff --git a/charts/kubedbcom-memcached-editor-options/ui/create-ui.yaml b/charts/kubedbcom-memcached-editor-options/ui/create-ui.yaml index 719b0c673a..50511b5074 100644 --- a/charts/kubedbcom-memcached-editor-options/ui/create-ui.yaml +++ b/charts/kubedbcom-memcached-editor-options/ui/create-ui.yaml @@ -230,6 +230,9 @@ step: - LoadBalancer schema: svcType type: select + init: + type: func + value: setServiceTemplate label: New Service Template schema: schema/properties/spec/properties/serviceTemplates type: array-object-form diff --git a/charts/kubedbcom-memcached-editor-options/ui/functions.js b/charts/kubedbcom-memcached-editor-options/ui/functions.js index feb8699454..967c6b4d79 100644 --- a/charts/kubedbcom-memcached-editor-options/ui/functions.js +++ b/charts/kubedbcom-memcached-editor-options/ui/functions.js @@ -909,6 +909,10 @@ export const useFunc = (model) => { }) } + function setServiceTemplate() { + const serviceTemplates = getValue(model, '/spec/admin/serviceTemplates') || [] + if (serviceTemplates.length) return serviceTemplates + } return { showReferSecretSwitch, onReferSecretChange, @@ -937,5 +941,6 @@ export const useFunc = (model) => { getAdminOptions, isToggleOn, getDefault, + setServiceTemplate, } } diff --git a/charts/kubedbcom-milvus-editor-options/ui/create-ui.yaml b/charts/kubedbcom-milvus-editor-options/ui/create-ui.yaml index 7ad7877c10..cf9547e0a8 100644 --- a/charts/kubedbcom-milvus-editor-options/ui/create-ui.yaml +++ b/charts/kubedbcom-milvus-editor-options/ui/create-ui.yaml @@ -576,6 +576,9 @@ step: - LoadBalancer schema: svcType type: select + init: + type: func + value: setServiceTemplate label: New Service Template schema: schema/properties/spec/properties/serviceTemplates type: array-object-form diff --git a/charts/kubedbcom-milvus-editor-options/ui/functions.js b/charts/kubedbcom-milvus-editor-options/ui/functions.js index 8307156eea..f8493e8eb9 100644 --- a/charts/kubedbcom-milvus-editor-options/ui/functions.js +++ b/charts/kubedbcom-milvus-editor-options/ui/functions.js @@ -1120,6 +1120,10 @@ export const useFunc = (model) => { } } + function setServiceTemplate() { + const serviceTemplates = getValue(model, '/spec/admin/serviceTemplates') || [] + if (serviceTemplates.length) return serviceTemplates + } return { onReferSecretChange, showReferSecretSwitch, @@ -1164,5 +1168,6 @@ export const useFunc = (model) => { isMetaStorageExternallyManaged, showEtcdOperatorWarning, getSecrets, + setServiceTemplate, } } diff --git a/charts/kubedbcom-mongodb-editor-options/ui/create-ui.yaml b/charts/kubedbcom-mongodb-editor-options/ui/create-ui.yaml index 1f5e778c36..83fcd8f2e7 100644 --- a/charts/kubedbcom-mongodb-editor-options/ui/create-ui.yaml +++ b/charts/kubedbcom-mongodb-editor-options/ui/create-ui.yaml @@ -659,6 +659,9 @@ step: - LoadBalancer schema: svcType type: select + init: + type: func + value: setServiceTemplate label: New Service Template schema: schema/properties/spec/properties/serviceTemplates type: array-object-form diff --git a/charts/kubedbcom-mongodb-editor-options/ui/functions.js b/charts/kubedbcom-mongodb-editor-options/ui/functions.js index c4a4ac84c6..a4a4be7e22 100644 --- a/charts/kubedbcom-mongodb-editor-options/ui/functions.js +++ b/charts/kubedbcom-mongodb-editor-options/ui/functions.js @@ -1444,6 +1444,10 @@ export const useFunc = (model) => { return } + function setServiceTemplate() { + const serviceTemplates = getValue(model, '/spec/admin/serviceTemplates') || [] + if (serviceTemplates.length) return serviceTemplates + } return { onReferSecretChange, showReferSecretSwitch, @@ -1501,5 +1505,6 @@ export const useFunc = (model) => { onHorizonsChange, isHorizonsValid, onTimestampChange, + setServiceTemplate, } } diff --git a/charts/kubedbcom-mssqlserver-editor-options/ui/create-ui.yaml b/charts/kubedbcom-mssqlserver-editor-options/ui/create-ui.yaml index a13b3d5278..5f22679744 100644 --- a/charts/kubedbcom-mssqlserver-editor-options/ui/create-ui.yaml +++ b/charts/kubedbcom-mssqlserver-editor-options/ui/create-ui.yaml @@ -371,6 +371,9 @@ step: - LoadBalancer schema: svcType type: select + init: + type: func + value: setServiceTemplate label: New Service Template schema: schema/properties/spec/properties/serviceTemplates type: array-object-form diff --git a/charts/kubedbcom-mssqlserver-editor-options/ui/functions.js b/charts/kubedbcom-mssqlserver-editor-options/ui/functions.js index 61b5981371..f8c71c6cf8 100644 --- a/charts/kubedbcom-mssqlserver-editor-options/ui/functions.js +++ b/charts/kubedbcom-mssqlserver-editor-options/ui/functions.js @@ -1332,6 +1332,10 @@ export const useFunc = (model) => { }) } + function setServiceTemplate() { + const serviceTemplates = getValue(model, '/spec/admin/serviceTemplates') || [] + if (serviceTemplates.length) return serviceTemplates + } return { showReferSecretSwitch, onReferSecretChange, @@ -1385,5 +1389,6 @@ export const useFunc = (model) => { showArchiver, filterNodeTopology, onTimestampChange, + setServiceTemplate, } } diff --git a/charts/kubedbcom-mysql-editor-options/ui/create-ui.yaml b/charts/kubedbcom-mysql-editor-options/ui/create-ui.yaml index 99d3d1f904..72264c9451 100644 --- a/charts/kubedbcom-mysql-editor-options/ui/create-ui.yaml +++ b/charts/kubedbcom-mysql-editor-options/ui/create-ui.yaml @@ -368,6 +368,9 @@ step: - LoadBalancer schema: svcType type: select + init: + type: func + value: setServiceTemplate label: New Service Template schema: schema/properties/spec/properties/serviceTemplates type: array-object-form diff --git a/charts/kubedbcom-mysql-editor-options/ui/functions.js b/charts/kubedbcom-mysql-editor-options/ui/functions.js index c792fa2c6d..902efb72b0 100644 --- a/charts/kubedbcom-mysql-editor-options/ui/functions.js +++ b/charts/kubedbcom-mysql-editor-options/ui/functions.js @@ -1341,6 +1341,10 @@ export const useFunc = (model) => { } } + function setServiceTemplate() { + const serviceTemplates = getValue(model, '/spec/admin/serviceTemplates') || [] + if (serviceTemplates.length) return serviceTemplates + } return { showReferSecretSwitch, onReferSecretChange, @@ -1388,5 +1392,6 @@ export const useFunc = (model) => { showArchiver, getAppBindings, onTimestampChange, + setServiceTemplate, } } diff --git a/charts/kubedbcom-neo4j-editor-options/ui/create-ui.yaml b/charts/kubedbcom-neo4j-editor-options/ui/create-ui.yaml index 10efd2d700..d9a96497ba 100644 --- a/charts/kubedbcom-neo4j-editor-options/ui/create-ui.yaml +++ b/charts/kubedbcom-neo4j-editor-options/ui/create-ui.yaml @@ -260,6 +260,9 @@ step: - LoadBalancer schema: svcType type: select + init: + type: func + value: setServiceTemplate label: New Service Template schema: schema/properties/spec/properties/serviceTemplates type: array-object-form diff --git a/charts/kubedbcom-neo4j-editor-options/ui/functions.js b/charts/kubedbcom-neo4j-editor-options/ui/functions.js index cfd40cdddb..07d6432b1a 100644 --- a/charts/kubedbcom-neo4j-editor-options/ui/functions.js +++ b/charts/kubedbcom-neo4j-editor-options/ui/functions.js @@ -1053,6 +1053,10 @@ export const useFunc = (model) => { return show } + function setServiceTemplate() { + const serviceTemplates = getValue(model, '/spec/admin/serviceTemplates') || [] + if (serviceTemplates.length) return serviceTemplates + } return { showReferSecretSwitch, onReferSecretChange, @@ -1089,5 +1093,6 @@ export const useFunc = (model) => { checkHostnameOrIP, onArchiverChange, showArchiverAlert, + setServiceTemplate, } } diff --git a/charts/kubedbcom-oracle-editor-options/ui/create-ui.yaml b/charts/kubedbcom-oracle-editor-options/ui/create-ui.yaml index 5267448385..01978ab8d6 100644 --- a/charts/kubedbcom-oracle-editor-options/ui/create-ui.yaml +++ b/charts/kubedbcom-oracle-editor-options/ui/create-ui.yaml @@ -261,6 +261,9 @@ step: - LoadBalancer schema: svcType type: select + init: + type: func + value: setServiceTemplate label: New Service Template schema: schema/properties/spec/properties/serviceTemplates type: array-object-form diff --git a/charts/kubedbcom-oracle-editor-options/ui/functions.js b/charts/kubedbcom-oracle-editor-options/ui/functions.js index 92e9c87c93..4463833e3a 100644 --- a/charts/kubedbcom-oracle-editor-options/ui/functions.js +++ b/charts/kubedbcom-oracle-editor-options/ui/functions.js @@ -1124,6 +1124,10 @@ export const useFunc = (model) => { return show } + function setServiceTemplate() { + const serviceTemplates = getValue(model, '/spec/admin/serviceTemplates') || [] + if (serviceTemplates.length) return serviceTemplates + } return { showReferSecretSwitch, onReferSecretChange, @@ -1168,5 +1172,6 @@ export const useFunc = (model) => { checkHostnameOrIP, onArchiverChange, showArchiverAlert, + setServiceTemplate, } } diff --git a/charts/kubedbcom-perconaxtradb-editor-options/ui/create-ui.yaml b/charts/kubedbcom-perconaxtradb-editor-options/ui/create-ui.yaml index f5801798ca..8f5df98765 100644 --- a/charts/kubedbcom-perconaxtradb-editor-options/ui/create-ui.yaml +++ b/charts/kubedbcom-perconaxtradb-editor-options/ui/create-ui.yaml @@ -245,6 +245,9 @@ step: - LoadBalancer schema: svcType type: select + init: + type: func + value: setServiceTemplate label: New Service Template schema: schema/properties/spec/properties/serviceTemplates type: array-object-form diff --git a/charts/kubedbcom-perconaxtradb-editor-options/ui/functions.js b/charts/kubedbcom-perconaxtradb-editor-options/ui/functions.js index 3bddedb958..418ae54547 100644 --- a/charts/kubedbcom-perconaxtradb-editor-options/ui/functions.js +++ b/charts/kubedbcom-perconaxtradb-editor-options/ui/functions.js @@ -970,6 +970,10 @@ export const useFunc = (model) => { }) } + function setServiceTemplate() { + const serviceTemplates = getValue(model, '/spec/admin/serviceTemplates') || [] + if (serviceTemplates.length) return serviceTemplates + } return { showReferSecretSwitch, onReferSecretChange, @@ -1006,5 +1010,6 @@ export const useFunc = (model) => { showSelectZone, setStorageClass, getDefault, + setServiceTemplate, } } diff --git a/charts/kubedbcom-pgbouncer-editor-options/ui/create-ui.yaml b/charts/kubedbcom-pgbouncer-editor-options/ui/create-ui.yaml index 510c443bd6..4fa3d004bd 100644 --- a/charts/kubedbcom-pgbouncer-editor-options/ui/create-ui.yaml +++ b/charts/kubedbcom-pgbouncer-editor-options/ui/create-ui.yaml @@ -261,6 +261,9 @@ step: - LoadBalancer schema: svcType type: select + init: + type: func + value: setServiceTemplate label: New Service Template schema: schema/properties/spec/properties/serviceTemplates type: array-object-form diff --git a/charts/kubedbcom-pgbouncer-editor-options/ui/functions.js b/charts/kubedbcom-pgbouncer-editor-options/ui/functions.js index 5172ff492e..431533a9ff 100644 --- a/charts/kubedbcom-pgbouncer-editor-options/ui/functions.js +++ b/charts/kubedbcom-pgbouncer-editor-options/ui/functions.js @@ -989,6 +989,10 @@ export const useFunc = (model) => { }) } + function setServiceTemplate() { + const serviceTemplates = getValue(model, '/spec/admin/serviceTemplates') || [] + if (serviceTemplates.length) return serviceTemplates + } return { showReferSecretSwitch, onReferSecretChange, @@ -1021,5 +1025,6 @@ export const useFunc = (model) => { isConfigDatabaseOn, clearConfiguration, getDefault, + setServiceTemplate, } } diff --git a/charts/kubedbcom-pgpool-editor-options/ui/create-ui.yaml b/charts/kubedbcom-pgpool-editor-options/ui/create-ui.yaml index 3b78d88fbe..e3c4951d7d 100644 --- a/charts/kubedbcom-pgpool-editor-options/ui/create-ui.yaml +++ b/charts/kubedbcom-pgpool-editor-options/ui/create-ui.yaml @@ -274,6 +274,9 @@ step: - LoadBalancer schema: svcType type: select + init: + type: func + value: setServiceTemplate label: New Service Template schema: schema/properties/spec/properties/serviceTemplates type: array-object-form diff --git a/charts/kubedbcom-pgpool-editor-options/ui/functions.js b/charts/kubedbcom-pgpool-editor-options/ui/functions.js index 6247cc9cb9..fe67850f18 100644 --- a/charts/kubedbcom-pgpool-editor-options/ui/functions.js +++ b/charts/kubedbcom-pgpool-editor-options/ui/functions.js @@ -1025,6 +1025,10 @@ export const useFunc = (model) => { }) } + function setServiceTemplate() { + const serviceTemplates = getValue(model, '/spec/admin/serviceTemplates') || [] + if (serviceTemplates.length) return serviceTemplates + } return { showReferSecretSwitch, onReferSecretChange, @@ -1059,5 +1063,6 @@ export const useFunc = (model) => { onRefChange, showAdditionalSettings, getDefault, + setServiceTemplate, } } diff --git a/charts/kubedbcom-postgres-editor-options/ui/create-ui.yaml b/charts/kubedbcom-postgres-editor-options/ui/create-ui.yaml index 2be50f67e0..de8ef23e2b 100644 --- a/charts/kubedbcom-postgres-editor-options/ui/create-ui.yaml +++ b/charts/kubedbcom-postgres-editor-options/ui/create-ui.yaml @@ -352,6 +352,9 @@ step: - LoadBalancer schema: svcType type: select + init: + type: func + value: setServiceTemplate label: New Service Template schema: schema/properties/spec/properties/serviceTemplates type: array-object-form diff --git a/charts/kubedbcom-postgres-editor-options/ui/functions.js b/charts/kubedbcom-postgres-editor-options/ui/functions.js index 44463e926f..68fa25d880 100644 --- a/charts/kubedbcom-postgres-editor-options/ui/functions.js +++ b/charts/kubedbcom-postgres-editor-options/ui/functions.js @@ -1347,6 +1347,10 @@ export const useFunc = (model) => { } } + function setServiceTemplate() { + const serviceTemplates = getValue(model, '/spec/admin/serviceTemplates') || [] + if (serviceTemplates.length) return serviceTemplates + } return { showReferSecretSwitch, onReferSecretChange, @@ -1395,5 +1399,6 @@ export const useFunc = (model) => { showArchiver, getAppBindings, onTimestampChange, + setServiceTemplate, } } diff --git a/charts/kubedbcom-proxysql-editor-options/ui/create-ui.yaml b/charts/kubedbcom-proxysql-editor-options/ui/create-ui.yaml index 78fe41c355..71874a1c9e 100644 --- a/charts/kubedbcom-proxysql-editor-options/ui/create-ui.yaml +++ b/charts/kubedbcom-proxysql-editor-options/ui/create-ui.yaml @@ -257,6 +257,9 @@ step: - LoadBalancer schema: svcType type: select + init: + type: func + value: setServiceTemplate label: New Service Template schema: schema/properties/spec/properties/serviceTemplates type: array-object-form diff --git a/charts/kubedbcom-proxysql-editor-options/ui/functions.js b/charts/kubedbcom-proxysql-editor-options/ui/functions.js index 9f082d3484..2fc6d7a494 100644 --- a/charts/kubedbcom-proxysql-editor-options/ui/functions.js +++ b/charts/kubedbcom-proxysql-editor-options/ui/functions.js @@ -1027,6 +1027,10 @@ export const useFunc = (model) => { }) } + function setServiceTemplate() { + const serviceTemplates = getValue(model, '/spec/admin/serviceTemplates') || [] + if (serviceTemplates.length) return serviceTemplates + } return { onReferSecretChange, showReferSecretSwitch, @@ -1065,5 +1069,6 @@ export const useFunc = (model) => { showSelectZone, showAdditionalSettings, getDefault, + setServiceTemplate, } } diff --git a/charts/kubedbcom-qdrant-editor-options/ui/create-ui.yaml b/charts/kubedbcom-qdrant-editor-options/ui/create-ui.yaml index 3286e3c5e1..02af57d7a6 100644 --- a/charts/kubedbcom-qdrant-editor-options/ui/create-ui.yaml +++ b/charts/kubedbcom-qdrant-editor-options/ui/create-ui.yaml @@ -273,6 +273,9 @@ step: - LoadBalancer schema: svcType type: select + init: + type: func + value: setServiceTemplate label: New Service Template schema: schema/properties/spec/properties/serviceTemplates type: array-object-form diff --git a/charts/kubedbcom-qdrant-editor-options/ui/functions.js b/charts/kubedbcom-qdrant-editor-options/ui/functions.js index f182d74b88..6e76126fcb 100644 --- a/charts/kubedbcom-qdrant-editor-options/ui/functions.js +++ b/charts/kubedbcom-qdrant-editor-options/ui/functions.js @@ -1033,6 +1033,10 @@ export const useFunc = (model) => { return !!modelPathValue && showReferSecret() } + function setServiceTemplate() { + const serviceTemplates = getValue(model, '/spec/admin/serviceTemplates') || [] + if (serviceTemplates.length) return serviceTemplates + } return { onReferSecretChange, showReferSecretSwitch, @@ -1068,5 +1072,6 @@ export const useFunc = (model) => { clearConfiguration, setBackup, getDefault, + setServiceTemplate, } } diff --git a/charts/kubedbcom-rabbitmq-editor-options/ui/create-ui.yaml b/charts/kubedbcom-rabbitmq-editor-options/ui/create-ui.yaml index a6d62e3b99..0a7093a057 100644 --- a/charts/kubedbcom-rabbitmq-editor-options/ui/create-ui.yaml +++ b/charts/kubedbcom-rabbitmq-editor-options/ui/create-ui.yaml @@ -263,6 +263,9 @@ step: - LoadBalancer schema: svcType type: select + init: + type: func + value: setServiceTemplate label: New Service Template schema: schema/properties/spec/properties/serviceTemplates type: array-object-form diff --git a/charts/kubedbcom-rabbitmq-editor-options/ui/functions.js b/charts/kubedbcom-rabbitmq-editor-options/ui/functions.js index 9d10465c77..8dd6bec885 100644 --- a/charts/kubedbcom-rabbitmq-editor-options/ui/functions.js +++ b/charts/kubedbcom-rabbitmq-editor-options/ui/functions.js @@ -1010,6 +1010,10 @@ export const useFunc = (model) => { }) } + function setServiceTemplate() { + const serviceTemplates = getValue(model, '/spec/admin/serviceTemplates') || [] + if (serviceTemplates.length) return serviceTemplates + } return { showReferSecretSwitch, onReferSecretChange, @@ -1048,5 +1052,6 @@ export const useFunc = (model) => { onModeChange, showAdditionalSettings, getDefault, + setServiceTemplate, } } diff --git a/charts/kubedbcom-redis-editor-options/ui/create-ui.yaml b/charts/kubedbcom-redis-editor-options/ui/create-ui.yaml index e1b3d7c081..020331ddf1 100644 --- a/charts/kubedbcom-redis-editor-options/ui/create-ui.yaml +++ b/charts/kubedbcom-redis-editor-options/ui/create-ui.yaml @@ -342,6 +342,9 @@ step: - LoadBalancer schema: svcType type: select + init: + type: func + value: setServiceTemplate label: New Service Template schema: schema/properties/spec/properties/serviceTemplates type: array-object-form diff --git a/charts/kubedbcom-redis-editor-options/ui/functions.js b/charts/kubedbcom-redis-editor-options/ui/functions.js index c17aed4885..c7e86d825f 100644 --- a/charts/kubedbcom-redis-editor-options/ui/functions.js +++ b/charts/kubedbcom-redis-editor-options/ui/functions.js @@ -1162,6 +1162,10 @@ export const useFunc = (model) => { return 'true' } + function setServiceTemplate() { + const serviceTemplates = getValue(model, '/spec/admin/serviceTemplates') || [] + if (serviceTemplates.length) return serviceTemplates + } return { checkIfFeatureOn, clearConfiguration, @@ -1213,5 +1217,6 @@ export const useFunc = (model) => { showSelectZone, showSentinelNameAndNamespace, updateAlertValue, + setServiceTemplate, } } diff --git a/charts/kubedbcom-singlestore-editor-options/ui/create-ui.yaml b/charts/kubedbcom-singlestore-editor-options/ui/create-ui.yaml index 04285d759d..a32cfe0412 100644 --- a/charts/kubedbcom-singlestore-editor-options/ui/create-ui.yaml +++ b/charts/kubedbcom-singlestore-editor-options/ui/create-ui.yaml @@ -402,6 +402,9 @@ step: - LoadBalancer schema: svcType type: select + init: + type: func + value: setServiceTemplate label: New Service Template schema: schema/properties/spec/properties/serviceTemplates type: array-object-form diff --git a/charts/kubedbcom-singlestore-editor-options/ui/functions.js b/charts/kubedbcom-singlestore-editor-options/ui/functions.js index e0e428fa7f..dac6663ea8 100644 --- a/charts/kubedbcom-singlestore-editor-options/ui/functions.js +++ b/charts/kubedbcom-singlestore-editor-options/ui/functions.js @@ -1069,6 +1069,10 @@ export const useFunc = (model) => { } else return getValue(model, `/spec/admin/${type}/toggle`) && bundleApiLoaded } + function setServiceTemplate() { + const serviceTemplates = getValue(model, '/spec/admin/serviceTemplates') || [] + if (serviceTemplates.length) return serviceTemplates + } return { clearConfiguration, dedicatedOnChange, @@ -1113,5 +1117,6 @@ export const useFunc = (model) => { getNodeTopology, checkIfFeatureOn, isToggleOn, + setServiceTemplate, } } diff --git a/charts/kubedbcom-solr-editor-options/ui/create-ui.yaml b/charts/kubedbcom-solr-editor-options/ui/create-ui.yaml index 41a2edc6ab..3d0d4f43f6 100644 --- a/charts/kubedbcom-solr-editor-options/ui/create-ui.yaml +++ b/charts/kubedbcom-solr-editor-options/ui/create-ui.yaml @@ -479,6 +479,9 @@ step: - LoadBalancer schema: svcType type: select + init: + type: func + value: setServiceTemplate label: New Service Template schema: schema/properties/spec/properties/serviceTemplates type: array-object-form diff --git a/charts/kubedbcom-solr-editor-options/ui/functions.js b/charts/kubedbcom-solr-editor-options/ui/functions.js index 0db247e8a2..1cf983ffbd 100644 --- a/charts/kubedbcom-solr-editor-options/ui/functions.js +++ b/charts/kubedbcom-solr-editor-options/ui/functions.js @@ -1060,6 +1060,10 @@ export const useFunc = (model) => { }) } + function setServiceTemplate() { + const serviceTemplates = getValue(model, '/spec/admin/serviceTemplates') || [] + if (serviceTemplates.length) return serviceTemplates + } return { clearConfiguration, filterNodeTopology, @@ -1100,5 +1104,6 @@ export const useFunc = (model) => { getNodeTopology, checkIfFeatureOn, isToggleOn, + setServiceTemplate, } } diff --git a/charts/kubedbcom-weaviate-editor-options/ui/create-ui.yaml b/charts/kubedbcom-weaviate-editor-options/ui/create-ui.yaml index f6e2176442..2350068d55 100644 --- a/charts/kubedbcom-weaviate-editor-options/ui/create-ui.yaml +++ b/charts/kubedbcom-weaviate-editor-options/ui/create-ui.yaml @@ -260,6 +260,9 @@ step: - LoadBalancer schema: svcType type: select + init: + type: func + value: setServiceTemplate label: New Service Template schema: schema/properties/spec/properties/serviceTemplates type: array-object-form diff --git a/charts/kubedbcom-weaviate-editor-options/ui/functions.js b/charts/kubedbcom-weaviate-editor-options/ui/functions.js index 24967f377c..2b827776df 100644 --- a/charts/kubedbcom-weaviate-editor-options/ui/functions.js +++ b/charts/kubedbcom-weaviate-editor-options/ui/functions.js @@ -1017,6 +1017,10 @@ export const useFunc = (model) => { return show } + function setServiceTemplate() { + const serviceTemplates = getValue(model, '/spec/admin/serviceTemplates') || [] + if (serviceTemplates.length) return serviceTemplates + } return { showReferSecretSwitch, onReferSecretChange, @@ -1049,5 +1053,6 @@ export const useFunc = (model) => { checkHostnameOrIP, onArchiverChange, showArchiverAlert, + setServiceTemplate, } } diff --git a/charts/kubedbcom-zookeeper-editor-options/ui/create-ui.yaml b/charts/kubedbcom-zookeeper-editor-options/ui/create-ui.yaml index 2e389a36fc..2fef396f75 100644 --- a/charts/kubedbcom-zookeeper-editor-options/ui/create-ui.yaml +++ b/charts/kubedbcom-zookeeper-editor-options/ui/create-ui.yaml @@ -262,6 +262,9 @@ step: - LoadBalancer schema: svcType type: select + init: + type: func + value: setServiceTemplate label: New Service Template schema: schema/properties/spec/properties/serviceTemplates type: array-object-form diff --git a/charts/kubedbcom-zookeeper-editor-options/ui/functions.js b/charts/kubedbcom-zookeeper-editor-options/ui/functions.js index 89cebdd062..b0118f2edd 100644 --- a/charts/kubedbcom-zookeeper-editor-options/ui/functions.js +++ b/charts/kubedbcom-zookeeper-editor-options/ui/functions.js @@ -1027,6 +1027,10 @@ export const useFunc = (model) => { // Add your implementation here if needed } + function setServiceTemplate() { + const serviceTemplates = getValue(model, '/spec/admin/serviceTemplates') || [] + if (serviceTemplates.length) return serviceTemplates + } return { showReferSecretSwitch, onReferSecretChange, @@ -1068,5 +1072,6 @@ export const useFunc = (model) => { showAdditionalSettings, getDefault, setResourceLimit, + setServiceTemplate, } }