@rulebricks/cli 2.1.7 → 2.3.2
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/README.md +51 -16
- package/cluster-setup/aws/README.md +96 -47
- package/cluster-setup/aws/check-aws-access.sh +216 -52
- package/cluster-setup/aws/parameters.json +13 -0
- package/cluster-setup/aws/rulebricks-cluster.cfn.yaml +355 -0
- package/cluster-setup/azure/README.md +103 -55
- package/cluster-setup/azure/check-aks-prereqs.sh +236 -56
- package/cluster-setup/azure/parameters.json +30 -0
- package/cluster-setup/azure/rulebricks-cluster.bicep +546 -0
- package/cluster-setup/gcp/README.md +51 -34
- package/cluster-setup/gcp/check-gke-prereqs.sh +222 -60
- package/dist/commands/backup.d.ts +5 -0
- package/dist/commands/backup.js +104 -0
- package/dist/commands/deploy.d.ts +3 -1
- package/dist/commands/deploy.js +226 -326
- package/dist/commands/destroy.d.ts +1 -1
- package/dist/commands/destroy.js +73 -123
- package/dist/commands/init.d.ts +5 -1
- package/dist/commands/init.js +78 -54
- package/dist/commands/list.d.ts +1 -0
- package/dist/commands/list.js +74 -0
- package/dist/commands/open.d.ts +1 -1
- package/dist/commands/open.js +4 -12
- package/dist/commands/redeploy.d.ts +6 -0
- package/dist/commands/redeploy.js +310 -0
- package/dist/commands/restore.d.ts +5 -0
- package/dist/commands/restore.js +338 -0
- package/dist/commands/status.js +62 -49
- package/dist/commands/upgrade.js +74 -51
- package/dist/components/DNSWaitScreen.d.ts +5 -1
- package/dist/components/DNSWaitScreen.js +47 -41
- package/dist/components/Wizard/WizardContext.d.ts +157 -36
- package/dist/components/Wizard/WizardContext.js +872 -160
- package/dist/components/Wizard/steps/CloudProviderStep.js +192 -107
- package/dist/components/Wizard/steps/DomainStep.js +5 -24
- package/dist/components/Wizard/steps/ExternalServicesStep.d.ts +6 -0
- package/dist/components/Wizard/steps/ExternalServicesStep.js +645 -0
- package/dist/components/Wizard/steps/FeatureConfigStep.d.ts +2 -1
- package/dist/components/Wizard/steps/FeatureConfigStep.js +739 -425
- package/dist/components/Wizard/steps/FeaturesStep.js +31 -35
- package/dist/components/Wizard/steps/ObservabilityStep.d.ts +6 -0
- package/dist/components/Wizard/steps/ObservabilityStep.js +137 -0
- package/dist/components/Wizard/steps/ReviewStep.d.ts +2 -1
- package/dist/components/Wizard/steps/ReviewStep.js +56 -12
- package/dist/components/Wizard/steps/StorageStep.d.ts +9 -0
- package/dist/components/Wizard/steps/StorageStep.js +592 -0
- package/dist/components/Wizard/steps/SupabaseCredentialsStep.js +20 -21
- package/dist/components/Wizard/steps/VersionStep.js +45 -23
- package/dist/components/Wizard/steps/index.d.ts +3 -3
- package/dist/components/Wizard/steps/index.js +3 -3
- package/dist/components/common/CommandApproval.d.ts +12 -0
- package/dist/components/common/CommandApproval.js +91 -0
- package/dist/components/common/DeploymentPicker.d.ts +14 -0
- package/dist/components/common/DeploymentPicker.js +16 -0
- package/dist/components/common/index.d.ts +2 -0
- package/dist/components/common/index.js +2 -0
- package/dist/index.js +94 -62
- package/dist/lib/cloudCli.d.ts +134 -63
- package/dist/lib/cloudCli.js +512 -220
- package/dist/lib/clusterSetupDefaults.d.ts +30 -0
- package/dist/lib/clusterSetupDefaults.js +64 -0
- package/dist/lib/commandApproval.d.ts +26 -0
- package/dist/lib/commandApproval.js +114 -0
- package/dist/lib/config.d.ts +12 -10
- package/dist/lib/config.js +91 -33
- package/dist/lib/configFixtures.d.ts +5 -0
- package/dist/lib/configFixtures.js +513 -0
- package/dist/lib/deploymentHealth.d.ts +32 -0
- package/dist/lib/deploymentHealth.js +157 -0
- package/dist/lib/dns.d.ts +1 -1
- package/dist/lib/dns.js +19 -1
- package/dist/lib/dns.test.d.ts +1 -0
- package/dist/lib/dns.test.js +27 -0
- package/dist/lib/dockerHub.d.ts +12 -1
- package/dist/lib/dockerHub.js +18 -8
- package/dist/lib/helm.d.ts +4 -0
- package/dist/lib/helm.js +16 -0
- package/dist/lib/helmValues.d.ts +25 -0
- package/dist/lib/helmValues.js +1841 -289
- package/dist/lib/helmValues.test.d.ts +1 -0
- package/dist/lib/helmValues.test.js +1012 -0
- package/dist/lib/htpasswd.d.ts +1 -0
- package/dist/lib/htpasswd.js +15 -0
- package/dist/lib/kubernetes.d.ts +124 -17
- package/dist/lib/kubernetes.js +576 -145
- package/dist/lib/secrets.d.ts +23 -0
- package/dist/lib/secrets.js +158 -0
- package/dist/lib/validateValues.d.ts +31 -0
- package/dist/lib/validateValues.js +253 -0
- package/dist/lib/versions.d.ts +82 -11
- package/dist/lib/versions.js +131 -31
- package/dist/lib/versions.test.d.ts +1 -0
- package/dist/lib/versions.test.js +81 -0
- package/dist/lib/wizardSteps.d.ts +14 -0
- package/dist/lib/wizardSteps.js +23 -0
- package/dist/lib/workloadIdentity.d.ts +26 -0
- package/dist/lib/workloadIdentity.js +323 -0
- package/dist/lib/workloadIdentity.test.d.ts +1 -0
- package/dist/lib/workloadIdentity.test.js +57 -0
- package/dist/types/index.d.ts +1860 -164
- package/dist/types/index.js +518 -295
- package/package.json +9 -4
- package/schema/values.schema.json +1934 -0
- package/cluster-setup/aws/cluster.yaml +0 -33
- package/cluster-setup/azure/main.bicep +0 -282
- package/cluster-setup/azure/main.parameters.json +0 -21
- package/dist/components/Wizard/steps/CredentialsStep.d.ts +0 -6
- package/dist/components/Wizard/steps/CredentialsStep.js +0 -22
- package/dist/components/Wizard/steps/DeploymentModeStep.d.ts +0 -5
- package/dist/components/Wizard/steps/DeploymentModeStep.js +0 -26
- package/dist/components/Wizard/steps/TierStep.d.ts +0 -6
- package/dist/components/Wizard/steps/TierStep.js +0 -29
- package/dist/lib/terraform.d.ts +0 -66
- package/dist/lib/terraform.js +0 -754
- package/terraform/aws/main.tf +0 -355
- package/terraform/azure/main.tf +0 -371
- package/terraform/gcp/main.tf +0 -407
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
import React, { ReactNode } from "react";
|
|
2
|
-
import { DeploymentConfig, CloudProvider, DatabaseType,
|
|
2
|
+
import { DeploymentConfig, CloudProvider, DatabaseType, NodeArchitecture, SSOProvider, DnsProvider, KafkaPreset, KafkaSaslMechanism, LoggingSink, CloudLoggingAuthMode, ObjectStorageProvider, MonitoringDestination, RemoteWriteAuthType, RemoteWriteDestination, EmailSubjects, EmailTemplates, ProfileConfig, TracingDestination } from "../../types/index.js";
|
|
3
3
|
export interface WizardState {
|
|
4
4
|
step: number;
|
|
5
5
|
name: string;
|
|
6
|
-
infrastructureMode: "existing" | "provision" | null;
|
|
7
6
|
provider: CloudProvider | null;
|
|
8
7
|
region: string;
|
|
9
8
|
clusterName: string;
|
|
@@ -14,7 +13,6 @@ export interface WizardState {
|
|
|
14
13
|
tlsEmail: string;
|
|
15
14
|
dnsProvider: DnsProvider;
|
|
16
15
|
dnsAutoManage: boolean;
|
|
17
|
-
existingExternalDns: boolean;
|
|
18
16
|
smtpHost: string;
|
|
19
17
|
smtpPort: number;
|
|
20
18
|
smtpUser: string;
|
|
@@ -31,7 +29,26 @@ export interface WizardState {
|
|
|
31
29
|
supabaseDbPassword: string;
|
|
32
30
|
supabaseDashboardUser: string;
|
|
33
31
|
supabaseDashboardPass: string;
|
|
34
|
-
|
|
32
|
+
nodeArchitecture: NodeArchitecture | null;
|
|
33
|
+
arm64TolerationRequired: boolean;
|
|
34
|
+
storageClass: string;
|
|
35
|
+
storageProvisioner: string;
|
|
36
|
+
schedulableNodeCount: number;
|
|
37
|
+
totalCpuCores: number;
|
|
38
|
+
totalMemoryGi: number;
|
|
39
|
+
eligibleCpuCores: number;
|
|
40
|
+
eligibleMemoryGi: number;
|
|
41
|
+
totalPersistentStorageGi: number;
|
|
42
|
+
storageProvider: ObjectStorageProvider | null;
|
|
43
|
+
storageBucket: string;
|
|
44
|
+
storageRegion: string;
|
|
45
|
+
storageCloudAuthMode: CloudLoggingAuthMode;
|
|
46
|
+
storageAwsIamRoleArn: string;
|
|
47
|
+
storageAzureBlobContainer: string;
|
|
48
|
+
storageAzureBlobClientId: string;
|
|
49
|
+
storageAzureBlobTenantId: string;
|
|
50
|
+
storageAzureBlobConnectionStringSecretRef: string;
|
|
51
|
+
storageGcpServiceAccountEmail: string;
|
|
35
52
|
aiEnabled: boolean;
|
|
36
53
|
openaiApiKey: string;
|
|
37
54
|
ssoEnabled: boolean;
|
|
@@ -39,7 +56,10 @@ export interface WizardState {
|
|
|
39
56
|
ssoUrl: string;
|
|
40
57
|
ssoClientId: string;
|
|
41
58
|
ssoClientSecret: string;
|
|
42
|
-
|
|
59
|
+
clickStackEnabled: boolean;
|
|
60
|
+
clickStackTelemetryRetentionDays: number;
|
|
61
|
+
clickHouseStorageSize: string;
|
|
62
|
+
metricsExportEnabled: boolean;
|
|
43
63
|
prometheusMonitoringDestination: MonitoringDestination | null;
|
|
44
64
|
prometheusRemoteWriteUrl: string;
|
|
45
65
|
prometheusRemoteWriteDestination: RemoteWriteDestination | null;
|
|
@@ -54,21 +74,72 @@ export interface WizardState {
|
|
|
54
74
|
prometheusRemoteWritePasswordSecretRef: string;
|
|
55
75
|
prometheusRemoteWriteBearerTokenSecretRef: string;
|
|
56
76
|
loggingSink: LoggingSink;
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
77
|
+
loggingPlatformCredential: string;
|
|
78
|
+
loggingPlatformDetail: string;
|
|
79
|
+
tracingEnabled: boolean;
|
|
80
|
+
tracingDestination: TracingDestination;
|
|
81
|
+
tracingElasticEndpoint: string;
|
|
82
|
+
tracingElasticAuthMode: "secret-token" | "api-key";
|
|
83
|
+
tracingElasticSecretToken: string;
|
|
84
|
+
tracingElasticApiKey: string;
|
|
85
|
+
tracingOtlpEndpoint: string;
|
|
86
|
+
tracingOtlpAuthMode: "none" | "bearer" | "api-key" | "header";
|
|
87
|
+
tracingOtlpHeaderName: string;
|
|
88
|
+
tracingOtlpToken: string;
|
|
89
|
+
tracingAzureConnectionString: string;
|
|
90
|
+
appLogsEnabled: boolean;
|
|
91
|
+
appLogsElasticEndpoint: string;
|
|
92
|
+
appLogsElasticIndex: string;
|
|
93
|
+
appLogsElasticAuthMode: "basic" | "api-key";
|
|
94
|
+
appLogsElasticUsername: string;
|
|
95
|
+
appLogsElasticPassword: string;
|
|
96
|
+
appLogsElasticApiKey: string;
|
|
66
97
|
customEmailsEnabled: boolean;
|
|
67
98
|
emailSubjects: EmailSubjects;
|
|
68
99
|
emailTemplates: EmailTemplates;
|
|
100
|
+
backupEnabled: boolean;
|
|
101
|
+
backupSchedule: string;
|
|
102
|
+
backupRetentionDays: number;
|
|
103
|
+
redisMode: "embedded" | "external";
|
|
104
|
+
redisHost: string;
|
|
105
|
+
redisPort: number;
|
|
106
|
+
redisPassword: string;
|
|
107
|
+
redisExistingSecret: string;
|
|
108
|
+
redisExistingSecretKey: string;
|
|
109
|
+
redisTls: boolean;
|
|
110
|
+
redisHttpApiEnabled: boolean;
|
|
111
|
+
redisHttpApiUrl: string;
|
|
112
|
+
redisHttpApiToken: string;
|
|
113
|
+
valkeyAdminEnabled: boolean;
|
|
114
|
+
valkeyAdminExposure: "internal" | "ingress";
|
|
115
|
+
valkeyAdminHostname: string;
|
|
116
|
+
valkeyAdminBasicAuthUsers: string[];
|
|
117
|
+
valkeyAdminAllowedIPs: string[];
|
|
118
|
+
redisExporterEnabled: boolean;
|
|
119
|
+
kafkaExporterEnabled: boolean;
|
|
120
|
+
kafkaMode: "embedded" | "external";
|
|
121
|
+
kafkaPreset: KafkaPreset | null;
|
|
122
|
+
kafkaBrokers: string;
|
|
123
|
+
kafkaTopic: string;
|
|
124
|
+
kafkaTopicPrefix: string;
|
|
125
|
+
kafkaProvisionTopics: boolean;
|
|
126
|
+
kafkaSsl: boolean;
|
|
127
|
+
kafkaSaslMechanism: KafkaSaslMechanism;
|
|
128
|
+
kafkaSaslRegion: string;
|
|
129
|
+
kafkaSaslUsername: string;
|
|
130
|
+
kafkaSaslPassword: string;
|
|
131
|
+
kafkaSaslExistingSecret: string;
|
|
132
|
+
kafkaIdentityAwsRoleArn: string;
|
|
133
|
+
kafkaIdentityGcpServiceAccountEmail: string;
|
|
134
|
+
kafkaIdentityAzureClientId: string;
|
|
135
|
+
postgresMode: "embedded" | "external";
|
|
136
|
+
postgresHost: string;
|
|
137
|
+
postgresPort: number;
|
|
138
|
+
postgresDatabase: string;
|
|
139
|
+
postgresMasterUsername: string;
|
|
140
|
+
postgresMasterPassword: string;
|
|
69
141
|
licenseKey: string;
|
|
70
|
-
|
|
71
|
-
hpsVersion: string;
|
|
142
|
+
version: string;
|
|
72
143
|
chartVersion: string;
|
|
73
144
|
}
|
|
74
145
|
type WizardAction = {
|
|
@@ -77,9 +148,6 @@ type WizardAction = {
|
|
|
77
148
|
} | {
|
|
78
149
|
type: "SET_NAME";
|
|
79
150
|
name: string;
|
|
80
|
-
} | {
|
|
81
|
-
type: "SET_INFRA_MODE";
|
|
82
|
-
mode: "existing" | "provision";
|
|
83
151
|
} | {
|
|
84
152
|
type: "SET_PROVIDER";
|
|
85
153
|
provider: CloudProvider;
|
|
@@ -101,18 +169,12 @@ type WizardAction = {
|
|
|
101
169
|
} | {
|
|
102
170
|
type: "SET_ADMIN_EMAIL";
|
|
103
171
|
email: string;
|
|
104
|
-
} | {
|
|
105
|
-
type: "SET_TLS_EMAIL";
|
|
106
|
-
email: string;
|
|
107
172
|
} | {
|
|
108
173
|
type: "SET_DNS_PROVIDER";
|
|
109
174
|
provider: DnsProvider;
|
|
110
175
|
} | {
|
|
111
176
|
type: "SET_DNS_AUTO_MANAGE";
|
|
112
177
|
autoManage: boolean;
|
|
113
|
-
} | {
|
|
114
|
-
type: "SET_EXISTING_EXTERNAL_DNS";
|
|
115
|
-
exists: boolean;
|
|
116
178
|
} | {
|
|
117
179
|
type: "SET_SMTP";
|
|
118
180
|
config: Partial<Pick<WizardState, "smtpHost" | "smtpPort" | "smtpUser" | "smtpPass" | "smtpFrom" | "smtpFromName">>;
|
|
@@ -126,8 +188,17 @@ type WizardAction = {
|
|
|
126
188
|
type: "SET_SUPABASE_SELF_HOSTED";
|
|
127
189
|
config: Partial<Pick<WizardState, "supabaseJwtSecret" | "supabaseDbPassword" | "supabaseDashboardUser" | "supabaseDashboardPass">>;
|
|
128
190
|
} | {
|
|
129
|
-
type: "
|
|
130
|
-
|
|
191
|
+
type: "SET_CLUSTER_CAPABILITIES";
|
|
192
|
+
nodeArchitecture: NodeArchitecture;
|
|
193
|
+
arm64TolerationRequired: boolean;
|
|
194
|
+
storageClass?: string;
|
|
195
|
+
storageProvisioner?: string;
|
|
196
|
+
schedulableNodeCount?: number;
|
|
197
|
+
totalCpuCores?: number;
|
|
198
|
+
totalMemoryGi?: number;
|
|
199
|
+
eligibleCpuCores?: number;
|
|
200
|
+
eligibleMemoryGi?: number;
|
|
201
|
+
totalPersistentStorageGi?: number;
|
|
131
202
|
} | {
|
|
132
203
|
type: "SET_AI_ENABLED";
|
|
133
204
|
enabled: boolean;
|
|
@@ -141,7 +212,13 @@ type WizardAction = {
|
|
|
141
212
|
type: "SET_SSO_CONFIG";
|
|
142
213
|
config: Partial<Pick<WizardState, "ssoProvider" | "ssoUrl" | "ssoClientId" | "ssoClientSecret">>;
|
|
143
214
|
} | {
|
|
144
|
-
type: "
|
|
215
|
+
type: "SET_CLICKSTACK_ENABLED";
|
|
216
|
+
enabled: boolean;
|
|
217
|
+
} | {
|
|
218
|
+
type: "SET_CLICKSTACK_CONFIG";
|
|
219
|
+
config: Partial<Pick<WizardState, "clickStackTelemetryRetentionDays" | "clickHouseStorageSize">>;
|
|
220
|
+
} | {
|
|
221
|
+
type: "SET_METRICS_EXPORT";
|
|
145
222
|
enabled: boolean;
|
|
146
223
|
} | {
|
|
147
224
|
type: "SET_PROMETHEUS_REMOTE_WRITE";
|
|
@@ -152,9 +229,36 @@ type WizardAction = {
|
|
|
152
229
|
} | {
|
|
153
230
|
type: "SET_LOGGING_SINK";
|
|
154
231
|
sink: LoggingSink;
|
|
232
|
+
} | {
|
|
233
|
+
type: "SET_STORAGE_CONFIG";
|
|
234
|
+
config: Partial<Pick<WizardState, "storageProvider" | "storageBucket" | "storageRegion" | "storageCloudAuthMode" | "storageAwsIamRoleArn" | "storageAzureBlobContainer" | "storageAzureBlobClientId" | "storageAzureBlobTenantId" | "storageAzureBlobConnectionStringSecretRef" | "storageGcpServiceAccountEmail">>;
|
|
155
235
|
} | {
|
|
156
236
|
type: "SET_LOGGING_CONFIG";
|
|
157
|
-
config: Partial<Pick<WizardState, "
|
|
237
|
+
config: Partial<Pick<WizardState, "loggingPlatformCredential" | "loggingPlatformDetail">>;
|
|
238
|
+
} | {
|
|
239
|
+
type: "SET_TRACING_ENABLED";
|
|
240
|
+
enabled: boolean;
|
|
241
|
+
} | {
|
|
242
|
+
type: "SET_TRACING_CONFIG";
|
|
243
|
+
config: Partial<Pick<WizardState, "tracingDestination" | "tracingElasticEndpoint" | "tracingElasticAuthMode" | "tracingElasticSecretToken" | "tracingElasticApiKey" | "tracingOtlpEndpoint" | "tracingOtlpAuthMode" | "tracingOtlpHeaderName" | "tracingOtlpToken" | "tracingAzureConnectionString">>;
|
|
244
|
+
} | {
|
|
245
|
+
type: "SET_APP_LOGS_ENABLED";
|
|
246
|
+
enabled: boolean;
|
|
247
|
+
} | {
|
|
248
|
+
type: "SET_APP_LOGS_CONFIG";
|
|
249
|
+
config: Partial<Pick<WizardState, "appLogsElasticEndpoint" | "appLogsElasticIndex" | "appLogsElasticAuthMode" | "appLogsElasticUsername" | "appLogsElasticPassword" | "appLogsElasticApiKey">>;
|
|
250
|
+
} | {
|
|
251
|
+
type: "SET_BACKUP_ENABLED";
|
|
252
|
+
enabled: boolean;
|
|
253
|
+
} | {
|
|
254
|
+
type: "SET_BACKUP_SCHEDULE";
|
|
255
|
+
schedule: string;
|
|
256
|
+
} | {
|
|
257
|
+
type: "SET_BACKUP_RETENTION_DAYS";
|
|
258
|
+
retentionDays: number;
|
|
259
|
+
} | {
|
|
260
|
+
type: "SET_EXTERNAL_SERVICES";
|
|
261
|
+
config: Partial<Pick<WizardState, "redisMode" | "redisHost" | "redisPort" | "redisPassword" | "redisExistingSecret" | "redisExistingSecretKey" | "redisTls" | "redisHttpApiEnabled" | "redisHttpApiUrl" | "redisHttpApiToken" | "valkeyAdminEnabled" | "valkeyAdminExposure" | "valkeyAdminHostname" | "valkeyAdminBasicAuthUsers" | "valkeyAdminAllowedIPs" | "redisExporterEnabled" | "kafkaExporterEnabled" | "kafkaMode" | "kafkaPreset" | "kafkaBrokers" | "kafkaTopic" | "kafkaTopicPrefix" | "kafkaProvisionTopics" | "kafkaSsl" | "kafkaSaslMechanism" | "kafkaSaslRegion" | "kafkaSaslUsername" | "kafkaSaslPassword" | "kafkaSaslExistingSecret" | "kafkaIdentityAwsRoleArn" | "kafkaIdentityGcpServiceAccountEmail" | "kafkaIdentityAzureClientId" | "postgresMode" | "postgresHost" | "postgresPort" | "postgresDatabase" | "postgresMasterUsername" | "postgresMasterPassword">>;
|
|
158
262
|
} | {
|
|
159
263
|
type: "SET_CUSTOM_EMAILS_ENABLED";
|
|
160
264
|
enabled: boolean;
|
|
@@ -168,9 +272,8 @@ type WizardAction = {
|
|
|
168
272
|
type: "SET_LICENSE_KEY";
|
|
169
273
|
key: string;
|
|
170
274
|
} | {
|
|
171
|
-
type: "
|
|
172
|
-
|
|
173
|
-
hpsVersion: string;
|
|
275
|
+
type: "SET_VERSION";
|
|
276
|
+
version: string;
|
|
174
277
|
} | {
|
|
175
278
|
type: "SET_CHART_VERSION";
|
|
176
279
|
version: string;
|
|
@@ -179,22 +282,40 @@ type WizardAction = {
|
|
|
179
282
|
} | {
|
|
180
283
|
type: "PREV_STEP";
|
|
181
284
|
};
|
|
285
|
+
/**
|
|
286
|
+
* Returns a list of human-readable reasons the wizard state can't be saved as a
|
|
287
|
+
* valid DeploymentConfig. Empty array means it's good to save. Shared by toConfig
|
|
288
|
+
* (which returns null when non-empty) and the review screen (which shows them),
|
|
289
|
+
* so users get a specific reason instead of a generic "invalid configuration".
|
|
290
|
+
*/
|
|
291
|
+
export declare function collectConfigIssues(state: WizardState): string[];
|
|
292
|
+
export declare function configToWizardState(config: DeploymentConfig, profile?: ProfileConfig | null): WizardState;
|
|
182
293
|
interface WizardContextValue {
|
|
183
294
|
state: WizardState;
|
|
184
295
|
dispatch: React.Dispatch<WizardAction>;
|
|
185
296
|
toConfig: (options?: {
|
|
186
|
-
|
|
297
|
+
nodeArchitecture?: NodeArchitecture;
|
|
298
|
+
arm64TolerationRequired?: boolean;
|
|
299
|
+
storageClass?: string;
|
|
300
|
+
storageProvisioner?: string;
|
|
301
|
+
schedulableNodeCount?: number;
|
|
302
|
+
totalCpuCores?: number;
|
|
303
|
+
totalMemoryGi?: number;
|
|
304
|
+
eligibleCpuCores?: number;
|
|
305
|
+
eligibleMemoryGi?: number;
|
|
306
|
+
totalPersistentStorageGi?: number;
|
|
187
307
|
}) => DeploymentConfig | null;
|
|
308
|
+
/** Human-readable reasons the current state can't be saved (empty = valid). */
|
|
309
|
+
configIssues: () => string[];
|
|
188
310
|
skipToStep: (stepId: string) => void;
|
|
189
311
|
profile: ProfileConfig | null;
|
|
190
|
-
/** Suggests a domain based on the profile's domain suffix and deployment name */
|
|
191
|
-
suggestDomain: (name: string) => string;
|
|
192
312
|
}
|
|
193
313
|
interface WizardProviderProps {
|
|
194
314
|
children: ReactNode;
|
|
195
315
|
initialName?: string;
|
|
316
|
+
initialState?: WizardState;
|
|
196
317
|
profile?: ProfileConfig | null;
|
|
197
318
|
}
|
|
198
|
-
export declare function WizardProvider({ children, initialName, profile, }: WizardProviderProps): import("react/jsx-runtime").JSX.Element;
|
|
319
|
+
export declare function WizardProvider({ children, initialName, initialState, profile, }: WizardProviderProps): import("react/jsx-runtime").JSX.Element;
|
|
199
320
|
export declare function useWizard(): WizardContextValue;
|
|
200
321
|
export {};
|