@settlemint/sdk-cli 2.4.0-pr4e4fa21a → 2.4.0-pr533b825c
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/dist/cli.js +734 -45
- package/dist/cli.js.map +35 -7
- package/package.json +5 -5
package/dist/cli.js
CHANGED
@@ -263840,7 +263840,7 @@ function pruneCurrentEnv(currentEnv, env2) {
|
|
263840
263840
|
var package_default = {
|
263841
263841
|
name: "@settlemint/sdk-cli",
|
263842
263842
|
description: "Command-line interface for SettleMint SDK, providing development tools and project management capabilities",
|
263843
|
-
version: "2.4.0-
|
263843
|
+
version: "2.4.0-pr533b825c",
|
263844
263844
|
type: "module",
|
263845
263845
|
private: false,
|
263846
263846
|
license: "FSL-1.1-MIT",
|
@@ -263891,10 +263891,10 @@ var package_default = {
|
|
263891
263891
|
"@inquirer/input": "4.1.12",
|
263892
263892
|
"@inquirer/password": "4.0.15",
|
263893
263893
|
"@inquirer/select": "4.2.3",
|
263894
|
-
"@settlemint/sdk-js": "2.4.0-
|
263895
|
-
"@settlemint/sdk-utils": "2.4.0-
|
263896
|
-
"@settlemint/sdk-viem": "2.4.0-
|
263897
|
-
"@types/node": "24.0.
|
263894
|
+
"@settlemint/sdk-js": "2.4.0-pr533b825c",
|
263895
|
+
"@settlemint/sdk-utils": "2.4.0-pr533b825c",
|
263896
|
+
"@settlemint/sdk-viem": "2.4.0-pr533b825c",
|
263897
|
+
"@types/node": "24.0.8",
|
263898
263898
|
"@types/semver": "7.7.0",
|
263899
263899
|
"@types/which": "3.0.4",
|
263900
263900
|
"get-tsconfig": "4.10.1",
|
@@ -288291,6 +288291,20 @@ var restartBlockchainNetwork = graphql(`
|
|
288291
288291
|
}
|
288292
288292
|
}
|
288293
288293
|
`, [BlockchainNetworkFragment]);
|
288294
|
+
var pauseBlockchainNetwork = graphql(`
|
288295
|
+
mutation PauseBlockchainNetwork($uniqueName: String!) {
|
288296
|
+
pauseBlockchainNetworkByUniqueName(uniqueName: $uniqueName) {
|
288297
|
+
...BlockchainNetwork
|
288298
|
+
}
|
288299
|
+
}
|
288300
|
+
`, [BlockchainNetworkFragment]);
|
288301
|
+
var resumeBlockchainNetwork = graphql(`
|
288302
|
+
mutation ResumeBlockchainNetwork($uniqueName: String!) {
|
288303
|
+
resumeBlockchainNetworkByUniqueName(uniqueName: $uniqueName) {
|
288304
|
+
...BlockchainNetwork
|
288305
|
+
}
|
288306
|
+
}
|
288307
|
+
`, [BlockchainNetworkFragment]);
|
288294
288308
|
var blockchainNetworkList = (gqlClient) => {
|
288295
288309
|
return async (applicationUniqueName) => {
|
288296
288310
|
const { blockchainNetworksByUniqueName: { items } } = await gqlClient.request(getBlockchainNetworks, { applicationUniqueName });
|
@@ -288325,6 +288339,14 @@ var blockchainNetworkRestart = (gqlClient) => async (blockchainNetworkUniqueName
|
|
288325
288339
|
const { restartBlockchainNetworkByUniqueName: blockchainNetwork } = await gqlClient.request(restartBlockchainNetwork, { uniqueName: blockchainNetworkUniqueName });
|
288326
288340
|
return blockchainNetwork;
|
288327
288341
|
};
|
288342
|
+
var blockchainNetworkPause = (gqlClient) => async (blockchainNetworkUniqueName) => {
|
288343
|
+
const { pauseBlockchainNetworkByUniqueName: blockchainNetwork } = await gqlClient.request(pauseBlockchainNetwork, { uniqueName: blockchainNetworkUniqueName });
|
288344
|
+
return blockchainNetwork;
|
288345
|
+
};
|
288346
|
+
var blockchainNetworkResume = (gqlClient) => async (blockchainNetworkUniqueName) => {
|
288347
|
+
const { resumeBlockchainNetworkByUniqueName: blockchainNetwork } = await gqlClient.request(resumeBlockchainNetwork, { uniqueName: blockchainNetworkUniqueName });
|
288348
|
+
return blockchainNetwork;
|
288349
|
+
};
|
288328
288350
|
var BlockchainNodeFragment = graphql(`
|
288329
288351
|
fragment BlockchainNode on BlockchainNode {
|
288330
288352
|
__typename
|
@@ -288458,6 +288480,20 @@ var restartBlockchainNode = graphql(`
|
|
288458
288480
|
}
|
288459
288481
|
}
|
288460
288482
|
`, [BlockchainNodeFragment]);
|
288483
|
+
var pauseBlockchainNode = graphql(`
|
288484
|
+
mutation PauseBlockchainNode($uniqueName: String!) {
|
288485
|
+
pauseBlockchainNodeByUniqueName(uniqueName: $uniqueName) {
|
288486
|
+
...BlockchainNode
|
288487
|
+
}
|
288488
|
+
}
|
288489
|
+
`, [BlockchainNodeFragment]);
|
288490
|
+
var resumeBlockchainNode = graphql(`
|
288491
|
+
mutation ResumeBlockchainNode($uniqueName: String!) {
|
288492
|
+
resumeBlockchainNodeByUniqueName(uniqueName: $uniqueName) {
|
288493
|
+
...BlockchainNode
|
288494
|
+
}
|
288495
|
+
}
|
288496
|
+
`, [BlockchainNodeFragment]);
|
288461
288497
|
var blockchainNodeList = (gqlClient) => {
|
288462
288498
|
return async (applicationUniqueName) => {
|
288463
288499
|
const { blockchainNodesByUniqueName: { items } } = await gqlClient.request(getBlockchainNodes, { applicationUniqueName });
|
@@ -288486,6 +288522,14 @@ var blockchainNodeRestart = (gqlClient) => async (blockchainNodeUniqueName) => {
|
|
288486
288522
|
const { restartBlockchainNodeByUniqueName: blockchainNode } = await gqlClient.request(restartBlockchainNode, { uniqueName: blockchainNodeUniqueName });
|
288487
288523
|
return blockchainNode;
|
288488
288524
|
};
|
288525
|
+
var blockchainNodePause = (gqlClient) => async (blockchainNodeUniqueName) => {
|
288526
|
+
const { pauseBlockchainNodeByUniqueName: blockchainNode } = await gqlClient.request(pauseBlockchainNode, { uniqueName: blockchainNodeUniqueName });
|
288527
|
+
return blockchainNode;
|
288528
|
+
};
|
288529
|
+
var blockchainNodeResume = (gqlClient) => async (blockchainNodeUniqueName) => {
|
288530
|
+
const { resumeBlockchainNodeByUniqueName: blockchainNode } = await gqlClient.request(resumeBlockchainNode, { uniqueName: blockchainNodeUniqueName });
|
288531
|
+
return blockchainNode;
|
288532
|
+
};
|
288489
288533
|
var CustomDeploymentFragment = graphql(`
|
288490
288534
|
fragment CustomDeployment on CustomDeployment {
|
288491
288535
|
id
|
@@ -288568,6 +288612,20 @@ var restartCustomDeployment = graphql(`
|
|
288568
288612
|
}
|
288569
288613
|
}
|
288570
288614
|
`, [CustomDeploymentFragment]);
|
288615
|
+
var pauseCustomDeployment = graphql(`
|
288616
|
+
mutation PauseCustomDeployment($uniqueName: String!) {
|
288617
|
+
pauseCustomDeploymentByUniqueName(uniqueName: $uniqueName) {
|
288618
|
+
...CustomDeployment
|
288619
|
+
}
|
288620
|
+
}
|
288621
|
+
`, [CustomDeploymentFragment]);
|
288622
|
+
var resumeCustomDeployment = graphql(`
|
288623
|
+
mutation ResumeCustomDeployment($uniqueName: String!) {
|
288624
|
+
resumeCustomDeploymentByUniqueName(uniqueName: $uniqueName) {
|
288625
|
+
...CustomDeployment
|
288626
|
+
}
|
288627
|
+
}
|
288628
|
+
`, [CustomDeploymentFragment]);
|
288571
288629
|
var customdeploymentList = (gqlClient) => {
|
288572
288630
|
return async (applicationUniqueName) => {
|
288573
288631
|
const { customDeploymentsByUniqueName: { items } } = await gqlClient.request(getCustomDeployments, { applicationUniqueName });
|
@@ -288604,6 +288662,14 @@ var customDeploymentRestart = (gqlClient) => async (customDeploymentUniqueName)
|
|
288604
288662
|
const { restartCustomDeploymentByUniqueName: customDeployment } = await gqlClient.request(restartCustomDeployment, { uniqueName: customDeploymentUniqueName });
|
288605
288663
|
return customDeployment;
|
288606
288664
|
};
|
288665
|
+
var customDeploymentPause = (gqlClient) => async (customDeploymentUniqueName) => {
|
288666
|
+
const { pauseCustomDeploymentByUniqueName: customDeployment } = await gqlClient.request(pauseCustomDeployment, { uniqueName: customDeploymentUniqueName });
|
288667
|
+
return customDeployment;
|
288668
|
+
};
|
288669
|
+
var customDeploymentResume = (gqlClient) => async (customDeploymentUniqueName) => {
|
288670
|
+
const { resumeCustomDeploymentByUniqueName: customDeployment } = await gqlClient.request(resumeCustomDeployment, { uniqueName: customDeploymentUniqueName });
|
288671
|
+
return customDeployment;
|
288672
|
+
};
|
288607
288673
|
var getFoundryEnvConfig = graphql(`
|
288608
288674
|
query GetFoundryEnvConfig($blockchainNodeUniqueName: String!) {
|
288609
288675
|
foundryEnvConfigByUniqueName(blockchainNodeUniqueName: $blockchainNodeUniqueName)
|
@@ -288680,6 +288746,20 @@ var restartLoadBalancer = graphql(`
|
|
288680
288746
|
}
|
288681
288747
|
}
|
288682
288748
|
`, [LoadBalancerFragment]);
|
288749
|
+
var pauseLoadBalancer = graphql(`
|
288750
|
+
mutation PauseLoadBalancer($uniqueName: String!) {
|
288751
|
+
pauseLoadBalancerByUniqueName(uniqueName: $uniqueName) {
|
288752
|
+
...LoadBalancer
|
288753
|
+
}
|
288754
|
+
}
|
288755
|
+
`, [LoadBalancerFragment]);
|
288756
|
+
var resumeLoadBalancer = graphql(`
|
288757
|
+
mutation ResumeLoadBalancer($uniqueName: String!) {
|
288758
|
+
resumeLoadBalancerByUniqueName(uniqueName: $uniqueName) {
|
288759
|
+
...LoadBalancer
|
288760
|
+
}
|
288761
|
+
}
|
288762
|
+
`, [LoadBalancerFragment]);
|
288683
288763
|
var loadBalancerRead = (gqlClient) => {
|
288684
288764
|
return async (loadBalancerUniqueName) => {
|
288685
288765
|
const { loadBalancerByUniqueName: loadBalancer } = await gqlClient.request(getLoadBalancer, { uniqueName: loadBalancerUniqueName });
|
@@ -288713,6 +288793,14 @@ var loadBalancerRestart = (gqlClient) => async (loadBalancerUniqueName) => {
|
|
288713
288793
|
const { restartLoadBalancerByUniqueName: loadBalancer } = await gqlClient.request(restartLoadBalancer, { uniqueName: loadBalancerUniqueName });
|
288714
288794
|
return loadBalancer;
|
288715
288795
|
};
|
288796
|
+
var loadBalancerPause = (gqlClient) => async (loadBalancerUniqueName) => {
|
288797
|
+
const { pauseLoadBalancerByUniqueName: loadBalancer } = await gqlClient.request(pauseLoadBalancer, { uniqueName: loadBalancerUniqueName });
|
288798
|
+
return loadBalancer;
|
288799
|
+
};
|
288800
|
+
var loadBalancerResume = (gqlClient) => async (loadBalancerUniqueName) => {
|
288801
|
+
const { resumeLoadBalancerByUniqueName: loadBalancer } = await gqlClient.request(resumeLoadBalancer, { uniqueName: loadBalancerUniqueName });
|
288802
|
+
return loadBalancer;
|
288803
|
+
};
|
288716
288804
|
var InsightsFragment = graphql(`
|
288717
288805
|
fragment Insights on Insights {
|
288718
288806
|
__typename
|
@@ -288786,6 +288874,20 @@ var restartInsights = graphql(`
|
|
288786
288874
|
}
|
288787
288875
|
}
|
288788
288876
|
`, [InsightsFragment]);
|
288877
|
+
var pauseInsights = graphql(`
|
288878
|
+
mutation PauseInsights($uniqueName: String!) {
|
288879
|
+
pauseInsightsByUniqueName(uniqueName: $uniqueName) {
|
288880
|
+
...Insights
|
288881
|
+
}
|
288882
|
+
}
|
288883
|
+
`, [InsightsFragment]);
|
288884
|
+
var resumeInsights = graphql(`
|
288885
|
+
mutation ResumeInsights($uniqueName: String!) {
|
288886
|
+
resumeInsightsByUniqueName(uniqueName: $uniqueName) {
|
288887
|
+
...Insights
|
288888
|
+
}
|
288889
|
+
}
|
288890
|
+
`, [InsightsFragment]);
|
288789
288891
|
var insightsList = (gqlClient) => {
|
288790
288892
|
return async (applicationUniqueName) => {
|
288791
288893
|
const { insightsListByUniqueName: { items } } = await gqlClient.request(getInsights, { applicationUniqueName });
|
@@ -288819,6 +288921,14 @@ var insightsRestart = (gqlClient) => async (insightsUniqueName) => {
|
|
288819
288921
|
const { restartInsightsByUniqueName: insights } = await gqlClient.request(restartInsights, { uniqueName: insightsUniqueName });
|
288820
288922
|
return insights;
|
288821
288923
|
};
|
288924
|
+
var insightsPause = (gqlClient) => async (insightsUniqueName) => {
|
288925
|
+
const { pauseInsightsByUniqueName: insights } = await gqlClient.request(pauseInsights, { uniqueName: insightsUniqueName });
|
288926
|
+
return insights;
|
288927
|
+
};
|
288928
|
+
var insightsResume = (gqlClient) => async (insightsUniqueName) => {
|
288929
|
+
const { resumeInsightsByUniqueName: insights } = await gqlClient.request(resumeInsights, { uniqueName: insightsUniqueName });
|
288930
|
+
return insights;
|
288931
|
+
};
|
288822
288932
|
var IntegrationFragment = graphql(`
|
288823
288933
|
fragment Integration on Integration {
|
288824
288934
|
__typename
|
@@ -288888,6 +288998,20 @@ var restartIntegrationTool = graphql(`
|
|
288888
288998
|
}
|
288889
288999
|
}
|
288890
289000
|
`, [IntegrationFragment]);
|
289001
|
+
var pauseIntegrationTool = graphql(`
|
289002
|
+
mutation PauseIntegrationTool($uniqueName: String!) {
|
289003
|
+
pauseIntegrationByUniqueName(uniqueName: $uniqueName) {
|
289004
|
+
...Integration
|
289005
|
+
}
|
289006
|
+
}
|
289007
|
+
`, [IntegrationFragment]);
|
289008
|
+
var resumeIntegrationTool = graphql(`
|
289009
|
+
mutation ResumeIntegrationTool($uniqueName: String!) {
|
289010
|
+
resumeIntegrationByUniqueName(uniqueName: $uniqueName) {
|
289011
|
+
...Integration
|
289012
|
+
}
|
289013
|
+
}
|
289014
|
+
`, [IntegrationFragment]);
|
288891
289015
|
var integrationToolList = (gqlClient) => {
|
288892
289016
|
return async (applicationUniqueName) => {
|
288893
289017
|
const { integrationsByUniqueName: { items } } = await gqlClient.request(getIntegrations, { applicationUniqueName });
|
@@ -288915,6 +289039,14 @@ var integrationToolRestart = (gqlClient) => async (integrationUniqueName) => {
|
|
288915
289039
|
const { restartIntegrationByUniqueName: integration } = await gqlClient.request(restartIntegrationTool, { uniqueName: integrationUniqueName });
|
288916
289040
|
return integration;
|
288917
289041
|
};
|
289042
|
+
var integrationToolPause = (gqlClient) => async (integrationUniqueName) => {
|
289043
|
+
const { pauseIntegrationByUniqueName: integration } = await gqlClient.request(pauseIntegrationTool, { uniqueName: integrationUniqueName });
|
289044
|
+
return integration;
|
289045
|
+
};
|
289046
|
+
var integrationToolResume = (gqlClient) => async (integrationUniqueName) => {
|
289047
|
+
const { resumeIntegrationByUniqueName: integration } = await gqlClient.request(resumeIntegrationTool, { uniqueName: integrationUniqueName });
|
289048
|
+
return integration;
|
289049
|
+
};
|
288918
289050
|
var StorageFragment = graphql(`
|
288919
289051
|
fragment Storage on Storage {
|
288920
289052
|
__typename
|
@@ -288984,6 +289116,20 @@ var restartStorage = graphql(`
|
|
288984
289116
|
}
|
288985
289117
|
}
|
288986
289118
|
`, [StorageFragment]);
|
289119
|
+
var pauseStorage = graphql(`
|
289120
|
+
mutation PauseStorage($uniqueName: String!) {
|
289121
|
+
pauseStorageByUniqueName(uniqueName: $uniqueName) {
|
289122
|
+
...Storage
|
289123
|
+
}
|
289124
|
+
}
|
289125
|
+
`, [StorageFragment]);
|
289126
|
+
var resumeStorage = graphql(`
|
289127
|
+
mutation ResumeStorage($uniqueName: String!) {
|
289128
|
+
resumeStorageByUniqueName(uniqueName: $uniqueName) {
|
289129
|
+
...Storage
|
289130
|
+
}
|
289131
|
+
}
|
289132
|
+
`, [StorageFragment]);
|
288987
289133
|
var storageList = (gqlClient) => {
|
288988
289134
|
return async (applicationUniqueName) => {
|
288989
289135
|
const { storagesByUniqueName: { items } } = await gqlClient.request(getStorages, { applicationUniqueName });
|
@@ -289011,6 +289157,14 @@ var storageRestart = (gqlClient) => async (storageUniqueName) => {
|
|
289011
289157
|
const { restartStorageByUniqueName: storage } = await gqlClient.request(restartStorage, { uniqueName: storageUniqueName });
|
289012
289158
|
return storage;
|
289013
289159
|
};
|
289160
|
+
var storagePause = (gqlClient) => async (storageUniqueName) => {
|
289161
|
+
const { pauseStorageByUniqueName: storage } = await gqlClient.request(pauseStorage, { uniqueName: storageUniqueName });
|
289162
|
+
return storage;
|
289163
|
+
};
|
289164
|
+
var storageResume = (gqlClient) => async (storageUniqueName) => {
|
289165
|
+
const { resumeStorageByUniqueName: storage } = await gqlClient.request(resumeStorage, { uniqueName: storageUniqueName });
|
289166
|
+
return storage;
|
289167
|
+
};
|
289014
289168
|
var MiddlewareFragment = graphql(`
|
289015
289169
|
fragment Middleware on Middleware {
|
289016
289170
|
__typename
|
@@ -289111,6 +289265,20 @@ var restartMiddleware = graphql(`
|
|
289111
289265
|
}
|
289112
289266
|
}
|
289113
289267
|
`, [MiddlewareFragment]);
|
289268
|
+
var pauseMiddleware = graphql(`
|
289269
|
+
mutation PauseMiddleware($uniqueName: String!) {
|
289270
|
+
pauseMiddlewareByUniqueName(uniqueName: $uniqueName) {
|
289271
|
+
...Middleware
|
289272
|
+
}
|
289273
|
+
}
|
289274
|
+
`, [MiddlewareFragment]);
|
289275
|
+
var resumeMiddleware = graphql(`
|
289276
|
+
mutation ResumeMiddleware($uniqueName: String!) {
|
289277
|
+
resumeMiddlewareByUniqueName(uniqueName: $uniqueName) {
|
289278
|
+
...Middleware
|
289279
|
+
}
|
289280
|
+
}
|
289281
|
+
`, [MiddlewareFragment]);
|
289114
289282
|
var middlewareList = (gqlClient) => {
|
289115
289283
|
return async (applicationUniqueName) => {
|
289116
289284
|
const { middlewaresByUniqueName: { items } } = await gqlClient.request(getMiddlewares, { applicationUniqueName });
|
@@ -289155,6 +289323,14 @@ var middlewareRestart = (gqlClient) => async (middlewareUniqueName) => {
|
|
289155
289323
|
const { restartMiddlewareByUniqueName: middleware } = await gqlClient.request(restartMiddleware, { uniqueName: middlewareUniqueName });
|
289156
289324
|
return middleware;
|
289157
289325
|
};
|
289326
|
+
var middlewarePause = (gqlClient) => async (middlewareUniqueName) => {
|
289327
|
+
const { pauseMiddlewareByUniqueName: middleware } = await gqlClient.request(pauseMiddleware, { uniqueName: middlewareUniqueName });
|
289328
|
+
return middleware;
|
289329
|
+
};
|
289330
|
+
var middlewareResume = (gqlClient) => async (middlewareUniqueName) => {
|
289331
|
+
const { resumeMiddlewareByUniqueName: middleware } = await gqlClient.request(resumeMiddleware, { uniqueName: middlewareUniqueName });
|
289332
|
+
return middleware;
|
289333
|
+
};
|
289158
289334
|
var getPlatformConfigQuery = graphql(`
|
289159
289335
|
query platformConfig {
|
289160
289336
|
config {
|
@@ -289287,6 +289463,20 @@ var restartPrivateKey = graphql(`
|
|
289287
289463
|
}
|
289288
289464
|
}
|
289289
289465
|
`, [PrivateKeyFragment]);
|
289466
|
+
var pausePrivateKey = graphql(`
|
289467
|
+
mutation PausePrivateKey($uniqueName: String!) {
|
289468
|
+
pausePrivateKeyByUniqueName(uniqueName: $uniqueName) {
|
289469
|
+
...PrivateKey
|
289470
|
+
}
|
289471
|
+
}
|
289472
|
+
`, [PrivateKeyFragment]);
|
289473
|
+
var resumePrivateKey = graphql(`
|
289474
|
+
mutation ResumePrivateKey($uniqueName: String!) {
|
289475
|
+
resumePrivateKeyByUniqueName(uniqueName: $uniqueName) {
|
289476
|
+
...PrivateKey
|
289477
|
+
}
|
289478
|
+
}
|
289479
|
+
`, [PrivateKeyFragment]);
|
289290
289480
|
var privateKeyList = (gqlClient) => {
|
289291
289481
|
return async (applicationUniqueName) => {
|
289292
289482
|
const { privateKeysByUniqueName: { items } } = await gqlClient.request(getPrivateKeys, { applicationUniqueName });
|
@@ -289325,6 +289515,14 @@ var privateKeyRestart = (gqlClient) => async (privateKeyUniqueName) => {
|
|
289325
289515
|
const { restartPrivateKeyByUniqueName: privateKey } = await gqlClient.request(restartPrivateKey, { uniqueName: privateKeyUniqueName });
|
289326
289516
|
return privateKey;
|
289327
289517
|
};
|
289518
|
+
var privateKeyPause = (gqlClient) => async (privateKeyUniqueName) => {
|
289519
|
+
const { pausePrivateKeyByUniqueName: privateKey } = await gqlClient.request(pausePrivateKey, { uniqueName: privateKeyUniqueName });
|
289520
|
+
return privateKey;
|
289521
|
+
};
|
289522
|
+
var privateKeyResume = (gqlClient) => async (privateKeyUniqueName) => {
|
289523
|
+
const { resumePrivateKeyByUniqueName: privateKey } = await gqlClient.request(resumePrivateKey, { uniqueName: privateKeyUniqueName });
|
289524
|
+
return privateKey;
|
289525
|
+
};
|
289328
289526
|
var ClientOptionsSchema = exports_external.object({
|
289329
289527
|
accessToken: AccessTokenSchema2,
|
289330
289528
|
instance: UrlSchema2
|
@@ -289404,57 +289602,75 @@ function createSettleMintClient(options) {
|
|
289404
289602
|
read: blockchainNetworkRead(gqlClient),
|
289405
289603
|
create: blockchainNetworkCreate(gqlClient),
|
289406
289604
|
delete: blockchainNetworkDelete(gqlClient),
|
289407
|
-
restart: blockchainNetworkRestart(gqlClient)
|
289605
|
+
restart: blockchainNetworkRestart(gqlClient),
|
289606
|
+
pause: blockchainNetworkPause(gqlClient),
|
289607
|
+
resume: blockchainNetworkResume(gqlClient)
|
289408
289608
|
},
|
289409
289609
|
blockchainNode: {
|
289410
289610
|
list: blockchainNodeList(gqlClient),
|
289411
289611
|
read: blockchainNodeRead(gqlClient),
|
289412
289612
|
create: blockchainNodeCreate(gqlClient),
|
289413
|
-
restart: blockchainNodeRestart(gqlClient)
|
289613
|
+
restart: blockchainNodeRestart(gqlClient),
|
289614
|
+
pause: blockchainNodePause(gqlClient),
|
289615
|
+
resume: blockchainNodeResume(gqlClient)
|
289414
289616
|
},
|
289415
289617
|
loadBalancer: {
|
289416
289618
|
list: loadBalancerList(gqlClient),
|
289417
289619
|
read: loadBalancerRead(gqlClient),
|
289418
289620
|
create: loadBalancerCreate(gqlClient),
|
289419
|
-
restart: loadBalancerRestart(gqlClient)
|
289621
|
+
restart: loadBalancerRestart(gqlClient),
|
289622
|
+
pause: loadBalancerPause(gqlClient),
|
289623
|
+
resume: loadBalancerResume(gqlClient)
|
289420
289624
|
},
|
289421
289625
|
middleware: {
|
289422
289626
|
list: middlewareList(gqlClient),
|
289423
289627
|
read: middlewareRead(gqlClient),
|
289424
289628
|
graphSubgraphs: graphMiddlewareSubgraphs(gqlClient),
|
289425
289629
|
create: middlewareCreate(gqlClient),
|
289426
|
-
restart: middlewareRestart(gqlClient)
|
289630
|
+
restart: middlewareRestart(gqlClient),
|
289631
|
+
pause: middlewarePause(gqlClient),
|
289632
|
+
resume: middlewareResume(gqlClient)
|
289427
289633
|
},
|
289428
289634
|
integrationTool: {
|
289429
289635
|
list: integrationToolList(gqlClient),
|
289430
289636
|
read: integrationToolRead(gqlClient),
|
289431
289637
|
create: integrationToolCreate(gqlClient),
|
289432
|
-
restart: integrationToolRestart(gqlClient)
|
289638
|
+
restart: integrationToolRestart(gqlClient),
|
289639
|
+
pause: integrationToolPause(gqlClient),
|
289640
|
+
resume: integrationToolResume(gqlClient)
|
289433
289641
|
},
|
289434
289642
|
storage: {
|
289435
289643
|
list: storageList(gqlClient),
|
289436
289644
|
read: storageRead(gqlClient),
|
289437
289645
|
create: storageCreate(gqlClient),
|
289438
|
-
restart: storageRestart(gqlClient)
|
289646
|
+
restart: storageRestart(gqlClient),
|
289647
|
+
pause: storagePause(gqlClient),
|
289648
|
+
resume: storageResume(gqlClient)
|
289439
289649
|
},
|
289440
289650
|
privateKey: {
|
289441
289651
|
list: privateKeyList(gqlClient),
|
289442
289652
|
read: privatekeyRead(gqlClient),
|
289443
289653
|
create: privateKeyCreate(gqlClient),
|
289444
|
-
restart: privateKeyRestart(gqlClient)
|
289654
|
+
restart: privateKeyRestart(gqlClient),
|
289655
|
+
pause: privateKeyPause(gqlClient),
|
289656
|
+
resume: privateKeyResume(gqlClient)
|
289445
289657
|
},
|
289446
289658
|
insights: {
|
289447
289659
|
list: insightsList(gqlClient),
|
289448
289660
|
read: insightsRead(gqlClient),
|
289449
289661
|
create: insightsCreate(gqlClient),
|
289450
|
-
restart: insightsRestart(gqlClient)
|
289662
|
+
restart: insightsRestart(gqlClient),
|
289663
|
+
pause: insightsPause(gqlClient),
|
289664
|
+
resume: insightsResume(gqlClient)
|
289451
289665
|
},
|
289452
289666
|
customDeployment: {
|
289453
289667
|
list: customdeploymentList(gqlClient),
|
289454
289668
|
read: customdeploymentRead(gqlClient),
|
289455
289669
|
create: customdeploymentCreate(gqlClient),
|
289456
289670
|
update: customdeploymentUpdate(gqlClient),
|
289457
|
-
restart: customDeploymentRestart(gqlClient)
|
289671
|
+
restart: customDeploymentRestart(gqlClient),
|
289672
|
+
pause: customDeploymentPause(gqlClient),
|
289673
|
+
resume: customDeploymentResume(gqlClient)
|
289458
289674
|
},
|
289459
289675
|
foundry: { env: getEnv(gqlClient) },
|
289460
289676
|
applicationAccessToken: { create: applicationAccessTokenCreate(gqlClient) },
|
@@ -326288,6 +326504,26 @@ async function waitForCompletion({
|
|
326288
326504
|
if (!service || !("read" in service)) {
|
326289
326505
|
throw new Error(`Service ${serviceType} does not support status checking`);
|
326290
326506
|
}
|
326507
|
+
function updateStatus(spinner2, message) {
|
326508
|
+
if (spinner2) {
|
326509
|
+
spinner2.text = message;
|
326510
|
+
} else {
|
326511
|
+
note(message);
|
326512
|
+
}
|
326513
|
+
}
|
326514
|
+
function isActionComplete(action2, status) {
|
326515
|
+
switch (action2) {
|
326516
|
+
case "pause":
|
326517
|
+
return status === "PAUSED" || status === "AUTO_PAUSED";
|
326518
|
+
case "resume":
|
326519
|
+
case "deploy":
|
326520
|
+
case "destroy":
|
326521
|
+
case "restart":
|
326522
|
+
return status === "COMPLETED";
|
326523
|
+
default:
|
326524
|
+
return false;
|
326525
|
+
}
|
326526
|
+
}
|
326291
326527
|
function showSpinner() {
|
326292
326528
|
return spinner({
|
326293
326529
|
startMessage: `Waiting for ${type4} to be ${getActionLabel(action)}`,
|
@@ -326297,33 +326533,17 @@ async function waitForCompletion({
|
|
326297
326533
|
while (true) {
|
326298
326534
|
try {
|
326299
326535
|
const resource = await service.read(uniqueName);
|
326300
|
-
if (resource.status === "COMPLETED") {
|
326301
|
-
if (spinner2) {
|
326302
|
-
spinner2.text = `${capitalizeFirstLetter2(type4)} is ${getActionLabel(action)}`;
|
326303
|
-
} else {
|
326304
|
-
note(`${capitalizeFirstLetter2(type4)} is ${getActionLabel(action)}`);
|
326305
|
-
}
|
326306
|
-
return true;
|
326307
|
-
}
|
326308
326536
|
if (resource.status === "FAILED") {
|
326309
|
-
|
326310
|
-
spinner2.text = `${capitalizeFirstLetter2(type4)} failed to ${getActionLabel(action)}`;
|
326311
|
-
} else {
|
326312
|
-
note(`${capitalizeFirstLetter2(type4)} failed to ${getActionLabel(action)}`);
|
326313
|
-
}
|
326537
|
+
updateStatus(spinner2, `${capitalizeFirstLetter2(type4)} failed to ${getActionLabel(action)}`);
|
326314
326538
|
return false;
|
326315
326539
|
}
|
326316
|
-
if (
|
326317
|
-
spinner2
|
326318
|
-
|
326319
|
-
note(`${capitalizeFirstLetter2(type4)} is not ready yet (status: ${resource.status})`);
|
326540
|
+
if (isActionComplete(action, resource.status)) {
|
326541
|
+
updateStatus(spinner2, `${capitalizeFirstLetter2(type4)} is ${getActionLabel(action)}`);
|
326542
|
+
return true;
|
326320
326543
|
}
|
326544
|
+
updateStatus(spinner2, `${capitalizeFirstLetter2(type4)} is not ready yet (status: ${resource.status})`);
|
326321
326545
|
} catch (_error) {
|
326322
|
-
|
326323
|
-
spinner2.text = `${capitalizeFirstLetter2(type4)} is not ready yet (status: UNKNOWN)`;
|
326324
|
-
} else {
|
326325
|
-
note(`${capitalizeFirstLetter2(type4)} is not ready yet (status: UNKNOWN)`);
|
326326
|
-
}
|
326546
|
+
updateStatus(spinner2, `${capitalizeFirstLetter2(type4)} is not ready yet (status: UNKNOWN)`);
|
326327
326547
|
}
|
326328
326548
|
if (Date.now() - startTime > maxTimeout) {
|
326329
326549
|
throw new TimeoutError2(`Operation timed out after ${maxTimeout / 60000} minutes for ${type4} with unique name ${uniqueName}`);
|
@@ -326346,13 +326566,20 @@ async function waitForCompletion({
|
|
326346
326566
|
}
|
326347
326567
|
}
|
326348
326568
|
function getActionLabel(action) {
|
326349
|
-
|
326350
|
-
|
326351
|
-
|
326352
|
-
|
326353
|
-
|
326569
|
+
switch (action) {
|
326570
|
+
case "restart":
|
326571
|
+
return "restarted";
|
326572
|
+
case "destroy":
|
326573
|
+
return "destroyed";
|
326574
|
+
case "pause":
|
326575
|
+
return "paused";
|
326576
|
+
case "resume":
|
326577
|
+
return "resumed";
|
326578
|
+
case "deploy":
|
326579
|
+
return "deployed";
|
326580
|
+
default:
|
326581
|
+
return "deployed";
|
326354
326582
|
}
|
326355
|
-
return "deployed";
|
326356
326583
|
}
|
326357
326584
|
|
326358
326585
|
// src/prompts/provider.prompt.ts
|
@@ -327950,6 +328177,237 @@ function deleteCommand() {
|
|
327950
328177
|
return new Command("delete").alias("d").description("Delete a resource in the SettleMint platform").addCommand(applicationDeleteCommand()).addCommand(workspaceDeleteCommand());
|
327951
328178
|
}
|
327952
328179
|
|
328180
|
+
// src/commands/platform/common/pause-command.ts
|
328181
|
+
function getPauseCommand({
|
328182
|
+
name: name3,
|
328183
|
+
type: type4,
|
328184
|
+
subType,
|
328185
|
+
alias,
|
328186
|
+
envKey,
|
328187
|
+
pauseFunction,
|
328188
|
+
usePersonalAccessToken = true
|
328189
|
+
}) {
|
328190
|
+
const commandName = sanitizeCommandName(name3);
|
328191
|
+
return new Command(commandName).alias(alias).description(`Pause a ${type4} in the SettleMint platform. Provide the ${type4} unique name or use 'default' to pause the default ${type4} from your .env file.`).usage(createExamples([
|
328192
|
+
{
|
328193
|
+
description: `Pauses the specified ${type4} by unique name`,
|
328194
|
+
command: `platform pause ${commandName} <${type4}-id>`
|
328195
|
+
},
|
328196
|
+
{
|
328197
|
+
description: `Pauses the default ${type4} in the production environment`,
|
328198
|
+
command: `platform pause ${commandName} default --prod`
|
328199
|
+
}
|
328200
|
+
])).argument("<unique-name>", `The unique name of the ${type4}, use 'default' to pause the default one from your .env file`).option("-a, --accept-defaults", "Accept the default and previously set values").option("--prod", "Connect to your production environment").option("-w, --wait", "Wait until paused").action(async (uniqueName, { acceptDefaults, prod, wait: wait2 }) => {
|
328201
|
+
intro(`Pausing ${type4} in the SettleMint platform`);
|
328202
|
+
const env2 = await loadEnv(false, !!prod);
|
328203
|
+
const instance = await instancePrompt({ env: env2, accept: acceptDefaults });
|
328204
|
+
const accessToken = await getApplicationOrPersonalAccessToken({
|
328205
|
+
env: env2,
|
328206
|
+
instance,
|
328207
|
+
prefer: usePersonalAccessToken ? "personal" : "application"
|
328208
|
+
});
|
328209
|
+
const settlemint = createSettleMintClient({
|
328210
|
+
accessToken,
|
328211
|
+
instance
|
328212
|
+
});
|
328213
|
+
const isDefaultUniqueName = uniqueName === "default";
|
328214
|
+
const serviceUniqueName = isDefaultUniqueName ? typeof env2[envKey] === "string" ? env2[envKey] : null : uniqueName;
|
328215
|
+
if (!serviceUniqueName) {
|
328216
|
+
cancel2(`No default ${type4} found in your .env file. Please provide a valid ${type4} unique name or set a default ${type4} first.`);
|
328217
|
+
}
|
328218
|
+
const result = await spinner({
|
328219
|
+
startMessage: `Pausing ${type4}`,
|
328220
|
+
task: async () => {
|
328221
|
+
return pauseFunction(settlemint, serviceUniqueName);
|
328222
|
+
},
|
328223
|
+
stopMessage: `${capitalizeFirstLetter2(type4)} pause initiated`
|
328224
|
+
});
|
328225
|
+
if (wait2) {
|
328226
|
+
const isPaused = await waitForCompletion({
|
328227
|
+
settlemint,
|
328228
|
+
type: type4,
|
328229
|
+
uniqueName: serviceUniqueName,
|
328230
|
+
action: "pause"
|
328231
|
+
});
|
328232
|
+
if (!isPaused) {
|
328233
|
+
throw new Error(`Failed to pause ${type4} ${serviceUniqueName}`);
|
328234
|
+
}
|
328235
|
+
}
|
328236
|
+
outro(`${capitalizeFirstLetter2(type4)} ${result.name} pause initiated successfully`);
|
328237
|
+
});
|
328238
|
+
}
|
328239
|
+
|
328240
|
+
// src/commands/platform/blockchain-network/pause.ts
|
328241
|
+
function blockchainNetworkPauseCommand() {
|
328242
|
+
return getPauseCommand({
|
328243
|
+
name: "blockchain-network",
|
328244
|
+
type: "blockchain network",
|
328245
|
+
alias: "bnw",
|
328246
|
+
envKey: "SETTLEMINT_BLOCKCHAIN_NETWORK",
|
328247
|
+
pauseFunction: async (settlemint, id) => {
|
328248
|
+
return settlemint.blockchainNetwork.pause(id);
|
328249
|
+
}
|
328250
|
+
});
|
328251
|
+
}
|
328252
|
+
|
328253
|
+
// src/commands/platform/blockchain-node/pause.ts
|
328254
|
+
function blockchainNodePauseCommand() {
|
328255
|
+
return getPauseCommand({
|
328256
|
+
name: "blockchain-node",
|
328257
|
+
type: "blockchain node",
|
328258
|
+
alias: "bn",
|
328259
|
+
envKey: "SETTLEMINT_BLOCKCHAIN_NODE",
|
328260
|
+
pauseFunction: async (settlemint, id) => {
|
328261
|
+
return settlemint.blockchainNode.pause(id);
|
328262
|
+
}
|
328263
|
+
});
|
328264
|
+
}
|
328265
|
+
|
328266
|
+
// src/commands/platform/custom-deployments/pause.ts
|
328267
|
+
function customDeploymentPauseCommand() {
|
328268
|
+
return getPauseCommand({
|
328269
|
+
name: "custom-deployment",
|
328270
|
+
type: "custom deployment",
|
328271
|
+
alias: "cd",
|
328272
|
+
envKey: "SETTLEMINT_CUSTOM_DEPLOYMENT",
|
328273
|
+
pauseFunction: async (settlemint, id) => {
|
328274
|
+
return settlemint.customDeployment.pause(id);
|
328275
|
+
}
|
328276
|
+
});
|
328277
|
+
}
|
328278
|
+
|
328279
|
+
// src/commands/platform/insights/blockscout/pause.ts
|
328280
|
+
function blockscoutPauseCommand() {
|
328281
|
+
return getPauseCommand({
|
328282
|
+
name: "blockscout",
|
328283
|
+
type: "insights",
|
328284
|
+
subType: "blockscout",
|
328285
|
+
alias: "bs",
|
328286
|
+
envKey: "SETTLEMINT_BLOCKSCOUT",
|
328287
|
+
pauseFunction: async (settlemint, id) => {
|
328288
|
+
return settlemint.insights.pause(id);
|
328289
|
+
}
|
328290
|
+
});
|
328291
|
+
}
|
328292
|
+
|
328293
|
+
// src/commands/platform/integration-tools/hasura/pause.ts
|
328294
|
+
function hasuraPauseCommand() {
|
328295
|
+
return getPauseCommand({
|
328296
|
+
name: "hasura",
|
328297
|
+
type: "integration tool",
|
328298
|
+
subType: "hasura",
|
328299
|
+
alias: "ha",
|
328300
|
+
envKey: "SETTLEMINT_HASURA",
|
328301
|
+
pauseFunction: async (settlemint, id) => {
|
328302
|
+
return settlemint.integrationTool.pause(id);
|
328303
|
+
}
|
328304
|
+
});
|
328305
|
+
}
|
328306
|
+
|
328307
|
+
// src/commands/platform/load-balancer/evm/pause.ts
|
328308
|
+
function evmLoadBalancerPauseCommand() {
|
328309
|
+
return getPauseCommand({
|
328310
|
+
name: "evm",
|
328311
|
+
type: "load balancer",
|
328312
|
+
subType: "evm",
|
328313
|
+
alias: "lb",
|
328314
|
+
envKey: "SETTLEMINT_BLOCKCHAIN_NODE_OR_LOAD_BALANCER",
|
328315
|
+
pauseFunction: async (settlemint, id) => {
|
328316
|
+
return settlemint.loadBalancer.pause(id);
|
328317
|
+
}
|
328318
|
+
});
|
328319
|
+
}
|
328320
|
+
|
328321
|
+
// src/commands/platform/middleware/graph/pause.ts
|
328322
|
+
function graphMiddlewarePauseCommand() {
|
328323
|
+
return getPauseCommand({
|
328324
|
+
name: "graph",
|
328325
|
+
type: "middleware",
|
328326
|
+
subType: "graph",
|
328327
|
+
alias: "gr",
|
328328
|
+
envKey: "SETTLEMINT_THEGRAPH",
|
328329
|
+
pauseFunction: async (settlemint, id) => {
|
328330
|
+
return settlemint.middleware.pause(id);
|
328331
|
+
}
|
328332
|
+
});
|
328333
|
+
}
|
328334
|
+
|
328335
|
+
// src/commands/platform/middleware/smart-contract-portal/pause.ts
|
328336
|
+
function smartContractPortalMiddlewarePauseCommand() {
|
328337
|
+
return getPauseCommand({
|
328338
|
+
name: "smart-contract-portal",
|
328339
|
+
type: "middleware",
|
328340
|
+
subType: "smart-contract-portal",
|
328341
|
+
alias: "scp",
|
328342
|
+
envKey: "SETTLEMINT_PORTAL",
|
328343
|
+
pauseFunction: async (settlemint, id) => {
|
328344
|
+
return settlemint.middleware.pause(id);
|
328345
|
+
}
|
328346
|
+
});
|
328347
|
+
}
|
328348
|
+
|
328349
|
+
// src/commands/platform/private-key/accessible-ecdsa-p256/pause.ts
|
328350
|
+
function accessibleEcdsaP256PrivateKeyPauseCommand() {
|
328351
|
+
return getPauseCommand({
|
328352
|
+
name: "accessible-ecdsa-p256",
|
328353
|
+
type: "private key",
|
328354
|
+
subType: "accessible-ecdsa-p256",
|
328355
|
+
alias: "acc",
|
328356
|
+
envKey: "SETTLEMINT_ACCESSIBLE_PRIVATE_KEY",
|
328357
|
+
pauseFunction: async (settlemint, id) => {
|
328358
|
+
return settlemint.privateKey.pause(id);
|
328359
|
+
}
|
328360
|
+
});
|
328361
|
+
}
|
328362
|
+
|
328363
|
+
// src/commands/platform/private-key/hd-ecdsa-p256/pause.ts
|
328364
|
+
function hdEcdsaP256PrivateKeyPauseCommand() {
|
328365
|
+
return getPauseCommand({
|
328366
|
+
name: "hd-ecdsa-p256",
|
328367
|
+
type: "private key",
|
328368
|
+
subType: "hd-ecdsa-p256",
|
328369
|
+
alias: "hd",
|
328370
|
+
envKey: "SETTLEMINT_HD_PRIVATE_KEY",
|
328371
|
+
pauseFunction: async (settlemint, id) => {
|
328372
|
+
return settlemint.privateKey.pause(id);
|
328373
|
+
}
|
328374
|
+
});
|
328375
|
+
}
|
328376
|
+
|
328377
|
+
// src/commands/platform/storage/ipfs/pause.ts
|
328378
|
+
function ipfsStoragePauseCommand() {
|
328379
|
+
return getPauseCommand({
|
328380
|
+
name: "ipfs",
|
328381
|
+
type: "storage",
|
328382
|
+
subType: "ipfs",
|
328383
|
+
alias: "ip",
|
328384
|
+
envKey: "SETTLEMINT_IPFS",
|
328385
|
+
pauseFunction: async (settlemint, id) => {
|
328386
|
+
return settlemint.storage.pause(id);
|
328387
|
+
}
|
328388
|
+
});
|
328389
|
+
}
|
328390
|
+
|
328391
|
+
// src/commands/platform/storage/minio/pause.ts
|
328392
|
+
function minioStoragePauseCommand() {
|
328393
|
+
return getPauseCommand({
|
328394
|
+
name: "minio",
|
328395
|
+
type: "storage",
|
328396
|
+
subType: "minio",
|
328397
|
+
alias: "m",
|
328398
|
+
envKey: "SETTLEMINT_MINIO",
|
328399
|
+
pauseFunction: async (settlemint, id) => {
|
328400
|
+
return settlemint.storage.pause(id);
|
328401
|
+
}
|
328402
|
+
});
|
328403
|
+
}
|
328404
|
+
|
328405
|
+
// src/commands/platform/pause.ts
|
328406
|
+
function pauseCommand() {
|
328407
|
+
const cmd2 = new Command("pause").description("Pause a resource in the SettleMint platform").addCommand(blockchainNodePauseCommand()).addCommand(blockchainNetworkPauseCommand()).addCommand(customDeploymentPauseCommand()).addCommand(blockscoutPauseCommand()).addCommand(hasuraPauseCommand()).addCommand(evmLoadBalancerPauseCommand()).addCommand(graphMiddlewarePauseCommand()).addCommand(smartContractPortalMiddlewarePauseCommand()).addCommand(accessibleEcdsaP256PrivateKeyPauseCommand()).addCommand(hdEcdsaP256PrivateKeyPauseCommand()).addCommand(ipfsStoragePauseCommand()).addCommand(minioStoragePauseCommand());
|
328408
|
+
return cmd2;
|
328409
|
+
}
|
328410
|
+
|
327953
328411
|
// src/commands/platform/common/restart-command.ts
|
327954
328412
|
function getRestartCommand({
|
327955
328413
|
name: name3,
|
@@ -327963,7 +328421,7 @@ function getRestartCommand({
|
|
327963
328421
|
const commandName = sanitizeCommandName(name3);
|
327964
328422
|
return new Command(commandName).alias(alias).description(`Restart a ${type4} in the SettleMint platform. Provide the ${type4} unique name or use 'default' to restart the default ${type4} from your .env file.`).usage(createExamples([
|
327965
328423
|
{
|
327966
|
-
description: `Restarts the specified ${type4} by
|
328424
|
+
description: `Restarts the specified ${type4} by unique name`,
|
327967
328425
|
command: `platform restart ${commandName}${subType ? ` ${subType}` : ""} <${type4}-id>`
|
327968
328426
|
},
|
327969
328427
|
{
|
@@ -328171,6 +328629,237 @@ function restartCommand() {
|
|
328171
328629
|
return cmd2;
|
328172
328630
|
}
|
328173
328631
|
|
328632
|
+
// src/commands/platform/common/resume-command.ts
|
328633
|
+
function getResumeCommand({
|
328634
|
+
name: name3,
|
328635
|
+
type: type4,
|
328636
|
+
subType,
|
328637
|
+
alias,
|
328638
|
+
envKey,
|
328639
|
+
resumeFunction,
|
328640
|
+
usePersonalAccessToken = true
|
328641
|
+
}) {
|
328642
|
+
const commandName = sanitizeCommandName(name3);
|
328643
|
+
return new Command(commandName).alias(alias).description(`Resume a ${type4} in the SettleMint platform. Provide the ${type4} unique name or use 'default' to resume the default ${type4} from your .env file.`).usage(createExamples([
|
328644
|
+
{
|
328645
|
+
description: `Resumes the specified ${type4} by unique name`,
|
328646
|
+
command: `platform resume ${commandName} <${type4}-id>`
|
328647
|
+
},
|
328648
|
+
{
|
328649
|
+
description: `Resumes the default ${type4} in the production environment`,
|
328650
|
+
command: `platform resume ${commandName} default --prod`
|
328651
|
+
}
|
328652
|
+
])).argument("<unique-name>", `The unique name of the ${type4}, use 'default' to resume the default one from your .env file`).option("-a, --accept-defaults", "Accept the default and previously set values").option("--prod", "Connect to your production environment").option("-w, --wait", "Wait until resumed").action(async (uniqueName, { acceptDefaults, prod, wait: wait2 }) => {
|
328653
|
+
intro(`Resuming ${type4} in the SettleMint platform`);
|
328654
|
+
const env2 = await loadEnv(false, !!prod);
|
328655
|
+
const instance = await instancePrompt({ env: env2, accept: acceptDefaults });
|
328656
|
+
const accessToken = await getApplicationOrPersonalAccessToken({
|
328657
|
+
env: env2,
|
328658
|
+
instance,
|
328659
|
+
prefer: usePersonalAccessToken ? "personal" : "application"
|
328660
|
+
});
|
328661
|
+
const settlemint = createSettleMintClient({
|
328662
|
+
accessToken,
|
328663
|
+
instance
|
328664
|
+
});
|
328665
|
+
const isDefaultUniqueName = uniqueName === "default";
|
328666
|
+
const serviceUniqueName = isDefaultUniqueName ? typeof env2[envKey] === "string" ? env2[envKey] : null : uniqueName;
|
328667
|
+
if (!serviceUniqueName) {
|
328668
|
+
cancel2(`No default ${type4} found in your .env file. Please provide a valid ${type4} unique name or set a default ${type4} first.`);
|
328669
|
+
}
|
328670
|
+
const result = await spinner({
|
328671
|
+
startMessage: `Resuming ${type4}`,
|
328672
|
+
task: async () => {
|
328673
|
+
return resumeFunction(settlemint, serviceUniqueName);
|
328674
|
+
},
|
328675
|
+
stopMessage: `${capitalizeFirstLetter2(type4)} resume initiated`
|
328676
|
+
});
|
328677
|
+
if (wait2) {
|
328678
|
+
const isResumed = await waitForCompletion({
|
328679
|
+
settlemint,
|
328680
|
+
type: type4,
|
328681
|
+
uniqueName: serviceUniqueName,
|
328682
|
+
action: "resume"
|
328683
|
+
});
|
328684
|
+
if (!isResumed) {
|
328685
|
+
throw new Error(`Failed to resume ${type4} ${serviceUniqueName}`);
|
328686
|
+
}
|
328687
|
+
}
|
328688
|
+
outro(`${capitalizeFirstLetter2(type4)} ${result.name} resume initiated successfully`);
|
328689
|
+
});
|
328690
|
+
}
|
328691
|
+
|
328692
|
+
// src/commands/platform/blockchain-network/resume.ts
|
328693
|
+
function blockchainNetworkResumeCommand() {
|
328694
|
+
return getResumeCommand({
|
328695
|
+
name: "blockchain-network",
|
328696
|
+
type: "blockchain network",
|
328697
|
+
alias: "bnw",
|
328698
|
+
envKey: "SETTLEMINT_BLOCKCHAIN_NETWORK",
|
328699
|
+
resumeFunction: async (settlemint, id) => {
|
328700
|
+
return settlemint.blockchainNetwork.resume(id);
|
328701
|
+
}
|
328702
|
+
});
|
328703
|
+
}
|
328704
|
+
|
328705
|
+
// src/commands/platform/blockchain-node/resume.ts
|
328706
|
+
function blockchainNodeResumeCommand() {
|
328707
|
+
return getResumeCommand({
|
328708
|
+
name: "blockchain-node",
|
328709
|
+
type: "blockchain node",
|
328710
|
+
alias: "bn",
|
328711
|
+
envKey: "SETTLEMINT_BLOCKCHAIN_NODE",
|
328712
|
+
resumeFunction: async (settlemint, id) => {
|
328713
|
+
return settlemint.blockchainNode.resume(id);
|
328714
|
+
}
|
328715
|
+
});
|
328716
|
+
}
|
328717
|
+
|
328718
|
+
// src/commands/platform/custom-deployments/resume.ts
|
328719
|
+
function customDeploymentResumeCommand() {
|
328720
|
+
return getResumeCommand({
|
328721
|
+
name: "custom-deployment",
|
328722
|
+
type: "custom deployment",
|
328723
|
+
alias: "cd",
|
328724
|
+
envKey: "SETTLEMINT_CUSTOM_DEPLOYMENT",
|
328725
|
+
resumeFunction: async (settlemint, id) => {
|
328726
|
+
return settlemint.customDeployment.resume(id);
|
328727
|
+
}
|
328728
|
+
});
|
328729
|
+
}
|
328730
|
+
|
328731
|
+
// src/commands/platform/insights/blockscout/resume.ts
|
328732
|
+
function blockscoutResumeCommand() {
|
328733
|
+
return getResumeCommand({
|
328734
|
+
name: "blockscout",
|
328735
|
+
type: "insights",
|
328736
|
+
subType: "blockscout",
|
328737
|
+
alias: "bs",
|
328738
|
+
envKey: "SETTLEMINT_BLOCKSCOUT",
|
328739
|
+
resumeFunction: async (settlemint, id) => {
|
328740
|
+
return settlemint.insights.resume(id);
|
328741
|
+
}
|
328742
|
+
});
|
328743
|
+
}
|
328744
|
+
|
328745
|
+
// src/commands/platform/integration-tools/hasura/resume.ts
|
328746
|
+
function hasuraResumeCommand() {
|
328747
|
+
return getResumeCommand({
|
328748
|
+
name: "hasura",
|
328749
|
+
type: "integration tool",
|
328750
|
+
subType: "hasura",
|
328751
|
+
alias: "ha",
|
328752
|
+
envKey: "SETTLEMINT_HASURA",
|
328753
|
+
resumeFunction: async (settlemint, id) => {
|
328754
|
+
return settlemint.integrationTool.resume(id);
|
328755
|
+
}
|
328756
|
+
});
|
328757
|
+
}
|
328758
|
+
|
328759
|
+
// src/commands/platform/load-balancer/evm/resume.ts
|
328760
|
+
function evmLoadBalancerResumeCommand() {
|
328761
|
+
return getResumeCommand({
|
328762
|
+
name: "evm",
|
328763
|
+
type: "load balancer",
|
328764
|
+
subType: "evm",
|
328765
|
+
alias: "lb",
|
328766
|
+
envKey: "SETTLEMINT_BLOCKCHAIN_NODE_OR_LOAD_BALANCER",
|
328767
|
+
resumeFunction: async (settlemint, id) => {
|
328768
|
+
return settlemint.loadBalancer.resume(id);
|
328769
|
+
}
|
328770
|
+
});
|
328771
|
+
}
|
328772
|
+
|
328773
|
+
// src/commands/platform/middleware/graph/resume.ts
|
328774
|
+
function graphMiddlewareResumeCommand() {
|
328775
|
+
return getResumeCommand({
|
328776
|
+
name: "graph",
|
328777
|
+
type: "middleware",
|
328778
|
+
subType: "graph",
|
328779
|
+
alias: "gr",
|
328780
|
+
envKey: "SETTLEMINT_THEGRAPH",
|
328781
|
+
resumeFunction: async (settlemint, id) => {
|
328782
|
+
return settlemint.middleware.resume(id);
|
328783
|
+
}
|
328784
|
+
});
|
328785
|
+
}
|
328786
|
+
|
328787
|
+
// src/commands/platform/middleware/smart-contract-portal/resume.ts
|
328788
|
+
function smartContractPortalMiddlewareResumeCommand() {
|
328789
|
+
return getResumeCommand({
|
328790
|
+
name: "smart-contract-portal",
|
328791
|
+
type: "middleware",
|
328792
|
+
subType: "smart-contract-portal",
|
328793
|
+
alias: "scp",
|
328794
|
+
envKey: "SETTLEMINT_PORTAL",
|
328795
|
+
resumeFunction: async (settlemint, id) => {
|
328796
|
+
return settlemint.middleware.resume(id);
|
328797
|
+
}
|
328798
|
+
});
|
328799
|
+
}
|
328800
|
+
|
328801
|
+
// src/commands/platform/private-key/accessible-ecdsa-p256/resume.ts
|
328802
|
+
function accessibleEcdsaP256PrivateKeyResumeCommand() {
|
328803
|
+
return getResumeCommand({
|
328804
|
+
name: "accessible-ecdsa-p256",
|
328805
|
+
type: "private key",
|
328806
|
+
subType: "accessible-ecdsa-p256",
|
328807
|
+
alias: "acc",
|
328808
|
+
envKey: "SETTLEMINT_ACCESSIBLE_PRIVATE_KEY",
|
328809
|
+
resumeFunction: async (settlemint, id) => {
|
328810
|
+
return settlemint.privateKey.resume(id);
|
328811
|
+
}
|
328812
|
+
});
|
328813
|
+
}
|
328814
|
+
|
328815
|
+
// src/commands/platform/private-key/hd-ecdsa-p256/resume.ts
|
328816
|
+
function hdEcdsaP256PrivateKeyResumeCommand() {
|
328817
|
+
return getResumeCommand({
|
328818
|
+
name: "hd-ecdsa-p256",
|
328819
|
+
type: "private key",
|
328820
|
+
subType: "hd-ecdsa-p256",
|
328821
|
+
alias: "hd",
|
328822
|
+
envKey: "SETTLEMINT_HD_PRIVATE_KEY",
|
328823
|
+
resumeFunction: async (settlemint, id) => {
|
328824
|
+
return settlemint.privateKey.resume(id);
|
328825
|
+
}
|
328826
|
+
});
|
328827
|
+
}
|
328828
|
+
|
328829
|
+
// src/commands/platform/storage/ipfs/resume.ts
|
328830
|
+
function ipfsStorageResumeCommand() {
|
328831
|
+
return getResumeCommand({
|
328832
|
+
name: "ipfs",
|
328833
|
+
type: "storage",
|
328834
|
+
subType: "ipfs",
|
328835
|
+
alias: "ip",
|
328836
|
+
envKey: "SETTLEMINT_IPFS",
|
328837
|
+
resumeFunction: async (settlemint, id) => {
|
328838
|
+
return settlemint.storage.resume(id);
|
328839
|
+
}
|
328840
|
+
});
|
328841
|
+
}
|
328842
|
+
|
328843
|
+
// src/commands/platform/storage/minio/resume.ts
|
328844
|
+
function minioStorageResumeCommand() {
|
328845
|
+
return getResumeCommand({
|
328846
|
+
name: "minio",
|
328847
|
+
type: "storage",
|
328848
|
+
subType: "minio",
|
328849
|
+
alias: "m",
|
328850
|
+
envKey: "SETTLEMINT_MINIO",
|
328851
|
+
resumeFunction: async (settlemint, id) => {
|
328852
|
+
return settlemint.storage.resume(id);
|
328853
|
+
}
|
328854
|
+
});
|
328855
|
+
}
|
328856
|
+
|
328857
|
+
// src/commands/platform/resume.ts
|
328858
|
+
function resumeCommand() {
|
328859
|
+
const cmd2 = new Command("resume").description("Resume a resource in the SettleMint platform").addCommand(blockchainNodeResumeCommand()).addCommand(blockchainNetworkResumeCommand()).addCommand(customDeploymentResumeCommand()).addCommand(blockscoutResumeCommand()).addCommand(hasuraResumeCommand()).addCommand(evmLoadBalancerResumeCommand()).addCommand(graphMiddlewareResumeCommand()).addCommand(smartContractPortalMiddlewareResumeCommand()).addCommand(accessibleEcdsaP256PrivateKeyResumeCommand()).addCommand(hdEcdsaP256PrivateKeyResumeCommand()).addCommand(ipfsStorageResumeCommand()).addCommand(minioStorageResumeCommand());
|
328860
|
+
return cmd2;
|
328861
|
+
}
|
328862
|
+
|
328174
328863
|
// src/commands/platform/custom-deployments/update.ts
|
328175
328864
|
function customDeploymentsUpdateCommand() {
|
328176
328865
|
return new Command("custom-deployment").alias("cd").argument("<tag>", "The tag to update the custom deployment to").option("--unique-name <uniqueName>", "The unique name of the custom deployment to update. If not provided, will use SETTLEMINT_CUSTOM_DEPLOYMENT from env").option("--prod", "Connect to your production environment").option("--wait", "Wait for the custom deployment to be redeployed").description("Update a custom deployment in the SettleMint platform").usage(createExamples([
|
@@ -328746,7 +329435,7 @@ function listCommand() {
|
|
328746
329435
|
|
328747
329436
|
// src/commands/platform.ts
|
328748
329437
|
function platformCommand() {
|
328749
|
-
return new Command("platform").description("Manage SettleMint platform resources").addCommand(configCommand()).addCommand(createCommand3()).addCommand(deleteCommand()).addCommand(listCommand()).addCommand(restartCommand()).addCommand(updateCommand());
|
329438
|
+
return new Command("platform").description("Manage SettleMint platform resources").addCommand(configCommand()).addCommand(createCommand3()).addCommand(deleteCommand()).addCommand(listCommand()).addCommand(pauseCommand()).addCommand(resumeCommand()).addCommand(restartCommand()).addCommand(updateCommand());
|
328750
329439
|
}
|
328751
329440
|
|
328752
329441
|
// src/commands/smart-contract-set/create.ts
|
@@ -330092,4 +330781,4 @@ async function sdkCliCommand(argv = process.argv) {
|
|
330092
330781
|
// src/cli.ts
|
330093
330782
|
sdkCliCommand();
|
330094
330783
|
|
330095
|
-
//# debugId=
|
330784
|
+
//# debugId=6C5AA40D6CB70A3764756E2164756E21
|