@settlemint/sdk-cli 0.7.0-pr9a96f6a → 0.7.0-prb3ff0d5
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 +120 -17
- package/dist/cli.js.map +11 -8
- package/package.json +3 -3
package/dist/cli.js
CHANGED
|
@@ -197427,7 +197427,7 @@ ${Bt.cyan(Yt)}
|
|
|
197427
197427
|
code: "ENOENT"
|
|
197428
197428
|
}), getPathInfo = (e9, t7) => {
|
|
197429
197429
|
var r6 = t7.colon || or;
|
|
197430
|
-
var i6 = e9.match(/\//) || nr && e9.match(/\\/) ? [""] : [...nr ? [process.cwd()] : [], ...(t7.path || "/home/runner/work/sdk/sdk/sdk/cli/node_modules/.bin:/home/runner/work/sdk/sdk/sdk/cli/node_modules/.bin:/home/runner/work/sdk/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/node_modules/.bin:/home/runner/work/node_modules/.bin:/home/runner/node_modules/.bin:/home/node_modules/.bin:/node_modules/.bin:/tmp/bunx-1001-turbo@latest/node_modules/.bin:/home/runner/work/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/node_modules/.bin:/home/runner/work/node_modules/.bin:/home/runner/node_modules/.bin:/home/node_modules/.bin:/node_modules/.bin:/opt/hostedtoolcache/node/22.12.0/x64/bin:/home/runner/.bun/bin:/tmp/tmp.
|
|
197430
|
+
var i6 = e9.match(/\//) || nr && e9.match(/\\/) ? [""] : [...nr ? [process.cwd()] : [], ...(t7.path || "/home/runner/work/sdk/sdk/sdk/cli/node_modules/.bin:/home/runner/work/sdk/sdk/sdk/cli/node_modules/.bin:/home/runner/work/sdk/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/node_modules/.bin:/home/runner/work/node_modules/.bin:/home/runner/node_modules/.bin:/home/node_modules/.bin:/node_modules/.bin:/tmp/bunx-1001-turbo@latest/node_modules/.bin:/home/runner/work/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/node_modules/.bin:/home/runner/work/node_modules/.bin:/home/runner/node_modules/.bin:/home/node_modules/.bin:/node_modules/.bin:/opt/hostedtoolcache/node/22.12.0/x64/bin:/home/runner/.bun/bin:/tmp/tmp.xnnLdHk4yF:/nsc/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/home/runner/.local/bin:/opt/pipx_bin:/home/runner/.config/composer/vendor/bin:/usr/local/.ghcup/bin:/snap/bin/:/usr/games:/usr/local/games:/home/linuxbrew/.linuxbrew/bin:/home/runner/.config/composer/vendor/bin:/home/runner/.dotnet/tools:/home/runner/.cargo/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin").split(r6)];
|
|
197431
197431
|
var n6 = nr ? t7.pathExt || process.env.PATHEXT || ".EXE;.CMD;.BAT;.COM" : "";
|
|
197432
197432
|
var a5 = nr ? n6.split(r6) : [""];
|
|
197433
197433
|
if (nr) {
|
|
@@ -200564,7 +200564,7 @@ ${whileRunning(e9)}`;
|
|
|
200564
200564
|
};
|
|
200565
200565
|
ni = Object.assign(async function _main() {
|
|
200566
200566
|
var e9 = new Cli({
|
|
200567
|
-
binaryVersion: "0.7.0-
|
|
200567
|
+
binaryVersion: "0.7.0-prb3ff0d5",
|
|
200568
200568
|
binaryLabel: "gql.tada CLI",
|
|
200569
200569
|
binaryName: "gql.tada"
|
|
200570
200570
|
});
|
|
@@ -218401,7 +218401,7 @@ var require_lib4 = __commonJS((exports, module) => {
|
|
|
218401
218401
|
var rRel = new RegExp(`^\\.${rSlash.source}`);
|
|
218402
218402
|
var getNotFoundError2 = (cmd2) => Object.assign(new Error(`not found: ${cmd2}`), { code: "ENOENT" });
|
|
218403
218403
|
var getPathInfo2 = (cmd2, {
|
|
218404
|
-
path: optPath = "/home/runner/work/sdk/sdk/sdk/cli/node_modules/.bin:/home/runner/work/sdk/sdk/sdk/cli/node_modules/.bin:/home/runner/work/sdk/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/node_modules/.bin:/home/runner/work/node_modules/.bin:/home/runner/node_modules/.bin:/home/node_modules/.bin:/node_modules/.bin:/tmp/bunx-1001-turbo@latest/node_modules/.bin:/home/runner/work/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/node_modules/.bin:/home/runner/work/node_modules/.bin:/home/runner/node_modules/.bin:/home/node_modules/.bin:/node_modules/.bin:/opt/hostedtoolcache/node/22.12.0/x64/bin:/home/runner/.bun/bin:/tmp/tmp.
|
|
218404
|
+
path: optPath = "/home/runner/work/sdk/sdk/sdk/cli/node_modules/.bin:/home/runner/work/sdk/sdk/sdk/cli/node_modules/.bin:/home/runner/work/sdk/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/node_modules/.bin:/home/runner/work/node_modules/.bin:/home/runner/node_modules/.bin:/home/node_modules/.bin:/node_modules/.bin:/tmp/bunx-1001-turbo@latest/node_modules/.bin:/home/runner/work/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/node_modules/.bin:/home/runner/work/node_modules/.bin:/home/runner/node_modules/.bin:/home/node_modules/.bin:/node_modules/.bin:/opt/hostedtoolcache/node/22.12.0/x64/bin:/home/runner/.bun/bin:/tmp/tmp.xnnLdHk4yF:/nsc/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/home/runner/.local/bin:/opt/pipx_bin:/home/runner/.config/composer/vendor/bin:/usr/local/.ghcup/bin:/snap/bin/:/usr/games:/usr/local/games:/home/linuxbrew/.linuxbrew/bin:/home/runner/.config/composer/vendor/bin:/home/runner/.dotnet/tools:/home/runner/.cargo/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin",
|
|
218405
218405
|
pathExt: optPathExt = process.env.PATHEXT,
|
|
218406
218406
|
delimiter: optDelimiter = delimiter
|
|
218407
218407
|
}) => {
|
|
@@ -218605,7 +218605,7 @@ var require_lib5 = __commonJS((exports, module) => {
|
|
|
218605
218605
|
let pathToInitial;
|
|
218606
218606
|
try {
|
|
218607
218607
|
pathToInitial = which.sync(initialCmd, {
|
|
218608
|
-
path: options.env && findInObject(options.env, "PATH") || "/home/runner/work/sdk/sdk/sdk/cli/node_modules/.bin:/home/runner/work/sdk/sdk/sdk/cli/node_modules/.bin:/home/runner/work/sdk/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/node_modules/.bin:/home/runner/work/node_modules/.bin:/home/runner/node_modules/.bin:/home/node_modules/.bin:/node_modules/.bin:/tmp/bunx-1001-turbo@latest/node_modules/.bin:/home/runner/work/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/node_modules/.bin:/home/runner/work/node_modules/.bin:/home/runner/node_modules/.bin:/home/node_modules/.bin:/node_modules/.bin:/opt/hostedtoolcache/node/22.12.0/x64/bin:/home/runner/.bun/bin:/tmp/tmp.
|
|
218608
|
+
path: options.env && findInObject(options.env, "PATH") || "/home/runner/work/sdk/sdk/sdk/cli/node_modules/.bin:/home/runner/work/sdk/sdk/sdk/cli/node_modules/.bin:/home/runner/work/sdk/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/node_modules/.bin:/home/runner/work/node_modules/.bin:/home/runner/node_modules/.bin:/home/node_modules/.bin:/node_modules/.bin:/tmp/bunx-1001-turbo@latest/node_modules/.bin:/home/runner/work/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/node_modules/.bin:/home/runner/work/node_modules/.bin:/home/runner/node_modules/.bin:/home/node_modules/.bin:/node_modules/.bin:/opt/hostedtoolcache/node/22.12.0/x64/bin:/home/runner/.bun/bin:/tmp/tmp.xnnLdHk4yF:/nsc/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/home/runner/.local/bin:/opt/pipx_bin:/home/runner/.config/composer/vendor/bin:/usr/local/.ghcup/bin:/snap/bin/:/usr/games:/usr/local/games:/home/linuxbrew/.linuxbrew/bin:/home/runner/.config/composer/vendor/bin:/home/runner/.dotnet/tools:/home/runner/.cargo/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin",
|
|
218609
218609
|
pathext: options.env && findInObject(options.env, "PATHEXT") || process.env.PATHEXT
|
|
218610
218610
|
}).toLowerCase();
|
|
218611
218611
|
} catch (err) {
|
|
@@ -219322,7 +219322,7 @@ var require_lib6 = __commonJS((exports, module) => {
|
|
|
219322
219322
|
var rRel = new RegExp(`^\\.${rSlash.source}`);
|
|
219323
219323
|
var getNotFoundError2 = (cmd2) => Object.assign(new Error(`not found: ${cmd2}`), { code: "ENOENT" });
|
|
219324
219324
|
var getPathInfo2 = (cmd2, {
|
|
219325
|
-
path: optPath = "/home/runner/work/sdk/sdk/sdk/cli/node_modules/.bin:/home/runner/work/sdk/sdk/sdk/cli/node_modules/.bin:/home/runner/work/sdk/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/node_modules/.bin:/home/runner/work/node_modules/.bin:/home/runner/node_modules/.bin:/home/node_modules/.bin:/node_modules/.bin:/tmp/bunx-1001-turbo@latest/node_modules/.bin:/home/runner/work/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/node_modules/.bin:/home/runner/work/node_modules/.bin:/home/runner/node_modules/.bin:/home/node_modules/.bin:/node_modules/.bin:/opt/hostedtoolcache/node/22.12.0/x64/bin:/home/runner/.bun/bin:/tmp/tmp.
|
|
219325
|
+
path: optPath = "/home/runner/work/sdk/sdk/sdk/cli/node_modules/.bin:/home/runner/work/sdk/sdk/sdk/cli/node_modules/.bin:/home/runner/work/sdk/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/node_modules/.bin:/home/runner/work/node_modules/.bin:/home/runner/node_modules/.bin:/home/node_modules/.bin:/node_modules/.bin:/tmp/bunx-1001-turbo@latest/node_modules/.bin:/home/runner/work/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/node_modules/.bin:/home/runner/work/node_modules/.bin:/home/runner/node_modules/.bin:/home/node_modules/.bin:/node_modules/.bin:/opt/hostedtoolcache/node/22.12.0/x64/bin:/home/runner/.bun/bin:/tmp/tmp.xnnLdHk4yF:/nsc/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/home/runner/.local/bin:/opt/pipx_bin:/home/runner/.config/composer/vendor/bin:/usr/local/.ghcup/bin:/snap/bin/:/usr/games:/usr/local/games:/home/linuxbrew/.linuxbrew/bin:/home/runner/.config/composer/vendor/bin:/home/runner/.dotnet/tools:/home/runner/.cargo/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin",
|
|
219326
219326
|
pathExt: optPathExt = process.env.PATHEXT,
|
|
219327
219327
|
delimiter: optDelimiter = delimiter
|
|
219328
219328
|
}) => {
|
|
@@ -235213,7 +235213,7 @@ var require_which2 = __commonJS((exports, module) => {
|
|
|
235213
235213
|
const colon = opt2.colon || COLON;
|
|
235214
235214
|
const pathEnv = cmd2.match(/\//) || isWindows2 && cmd2.match(/\\/) ? [""] : [
|
|
235215
235215
|
...isWindows2 ? [process.cwd()] : [],
|
|
235216
|
-
...(opt2.path || "/home/runner/work/sdk/sdk/sdk/cli/node_modules/.bin:/home/runner/work/sdk/sdk/sdk/cli/node_modules/.bin:/home/runner/work/sdk/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/node_modules/.bin:/home/runner/work/node_modules/.bin:/home/runner/node_modules/.bin:/home/node_modules/.bin:/node_modules/.bin:/tmp/bunx-1001-turbo@latest/node_modules/.bin:/home/runner/work/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/node_modules/.bin:/home/runner/work/node_modules/.bin:/home/runner/node_modules/.bin:/home/node_modules/.bin:/node_modules/.bin:/opt/hostedtoolcache/node/22.12.0/x64/bin:/home/runner/.bun/bin:/tmp/tmp.
|
|
235216
|
+
...(opt2.path || "/home/runner/work/sdk/sdk/sdk/cli/node_modules/.bin:/home/runner/work/sdk/sdk/sdk/cli/node_modules/.bin:/home/runner/work/sdk/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/node_modules/.bin:/home/runner/work/node_modules/.bin:/home/runner/node_modules/.bin:/home/node_modules/.bin:/node_modules/.bin:/tmp/bunx-1001-turbo@latest/node_modules/.bin:/home/runner/work/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/sdk/node_modules/.bin:/home/runner/work/sdk/node_modules/.bin:/home/runner/work/node_modules/.bin:/home/runner/node_modules/.bin:/home/node_modules/.bin:/node_modules/.bin:/opt/hostedtoolcache/node/22.12.0/x64/bin:/home/runner/.bun/bin:/tmp/tmp.xnnLdHk4yF:/nsc/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/home/runner/.local/bin:/opt/pipx_bin:/home/runner/.config/composer/vendor/bin:/usr/local/.ghcup/bin:/snap/bin/:/usr/games:/usr/local/games:/home/linuxbrew/.linuxbrew/bin:/home/runner/.config/composer/vendor/bin:/home/runner/.dotnet/tools:/home/runner/.cargo/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin").split(colon)
|
|
235217
235217
|
];
|
|
235218
235218
|
const pathExtExe = isWindows2 ? opt2.pathExt || process.env.PATHEXT || ".EXE;.CMD;.BAT;.COM" : "";
|
|
235219
235219
|
const pathExt = isWindows2 ? pathExtExe.split(colon) : [""];
|
|
@@ -267876,7 +267876,7 @@ export const { client: theGraphClient${nameSuffix}, graphql: theGraphGraphql${na
|
|
|
267876
267876
|
Timestamp: string;
|
|
267877
267877
|
};
|
|
267878
267878
|
}>({
|
|
267879
|
-
instances: JSON.parse(process.env.SETTLEMINT_THEGRAPH_SUBGRAPHS_ENDPOINTS
|
|
267879
|
+
instances: JSON.parse(process.env.SETTLEMINT_THEGRAPH_SUBGRAPHS_ENDPOINTS || '[]'),
|
|
267880
267880
|
accessToken: process.env.SETTLEMINT_ACCESS_TOKEN!, // undefined in browser, by design to not leak the secrets
|
|
267881
267881
|
subgraphName: "${name2}",
|
|
267882
267882
|
});`
|
|
@@ -273258,7 +273258,7 @@ function connectCommand() {
|
|
|
273258
273258
|
var package_default = {
|
|
273259
273259
|
name: "@settlemint/sdk-cli",
|
|
273260
273260
|
description: "SettleMint SDK, integrate SettleMint into your application with ease.",
|
|
273261
|
-
version: "0.7.0-
|
|
273261
|
+
version: "0.7.0-prb3ff0d5",
|
|
273262
273262
|
type: "module",
|
|
273263
273263
|
private: false,
|
|
273264
273264
|
license: "FSL-1.1-MIT",
|
|
@@ -273309,8 +273309,8 @@ var package_default = {
|
|
|
273309
273309
|
"@inquirer/input": "4.1.0",
|
|
273310
273310
|
"@inquirer/password": "4.0.3",
|
|
273311
273311
|
"@inquirer/select": "4.0.3",
|
|
273312
|
-
"@settlemint/sdk-js": "0.7.0-
|
|
273313
|
-
"@settlemint/sdk-utils": "0.7.0-
|
|
273312
|
+
"@settlemint/sdk-js": "0.7.0-prb3ff0d5",
|
|
273313
|
+
"@settlemint/sdk-utils": "0.7.0-prb3ff0d5",
|
|
273314
273314
|
"get-tsconfig": "4.8.1",
|
|
273315
273315
|
giget: "1.2.3"
|
|
273316
273316
|
},
|
|
@@ -274389,7 +274389,7 @@ ${createExamples(examples)}`).argument("<name>", `The ${type4} name`).option("-a
|
|
|
274389
274389
|
intro(`Creating ${type4} in the SettleMint platform`);
|
|
274390
274390
|
const autoAccept = !!acceptDefaults || is_in_ci_default;
|
|
274391
274391
|
const env2 = await loadEnv2(false, !!prod);
|
|
274392
|
-
const instance = await instancePrompt(env2, autoAccept);
|
|
274392
|
+
const instance = env2.SETTLEMINT_INSTANCE ?? await instancePrompt(env2, autoAccept);
|
|
274393
274393
|
const accessToken = usePersonalAccessToken ? (await getInstanceCredentials(instance))?.personalAccessToken : env2.SETTLEMINT_ACCESS_TOKEN;
|
|
274394
274394
|
if (!accessToken) {
|
|
274395
274395
|
return missingAccessTokenError();
|
|
@@ -274515,7 +274515,7 @@ function blockchainNetworkBesuCreateCommand() {
|
|
|
274515
274515
|
|
|
274516
274516
|
// src/commands/platform/blockchain-network/create.ts
|
|
274517
274517
|
function blockchainNetworkCreateCommand() {
|
|
274518
|
-
return new Command2("blockchain-network").alias("
|
|
274518
|
+
return new Command2("blockchain-network").alias("bnw").description("Create a blockchain network in the SettleMint platform").addCommand(blockchainNetworkBesuCreateCommand());
|
|
274519
274519
|
}
|
|
274520
274520
|
|
|
274521
274521
|
// src/commands/platform/workspace/create.ts
|
|
@@ -274787,6 +274787,111 @@ function applicationCreateCommand() {
|
|
|
274787
274787
|
});
|
|
274788
274788
|
}
|
|
274789
274789
|
|
|
274790
|
+
// src/commands/connect/blockchain-network.prompt.ts
|
|
274791
|
+
async function blockchainNetworkPrompt(env2, networks, accept) {
|
|
274792
|
+
if (networks.length === 0) {
|
|
274793
|
+
return;
|
|
274794
|
+
}
|
|
274795
|
+
const defaultNetwork = networks.find((network2) => network2.id === env2.SETTLEMINT_BLOCKCHAIN_NETWORK) ?? (networks.length === 1 ? networks[0] : undefined);
|
|
274796
|
+
const defaultPossible = accept;
|
|
274797
|
+
if (defaultPossible) {
|
|
274798
|
+
return defaultNetwork;
|
|
274799
|
+
}
|
|
274800
|
+
const network = await esm_default2({
|
|
274801
|
+
message: "Which blockchain network do you want to connect to?",
|
|
274802
|
+
choices: [
|
|
274803
|
+
...networks.map((network2) => ({
|
|
274804
|
+
name: network2.name,
|
|
274805
|
+
value: network2
|
|
274806
|
+
})),
|
|
274807
|
+
{
|
|
274808
|
+
name: "None",
|
|
274809
|
+
value: undefined
|
|
274810
|
+
}
|
|
274811
|
+
],
|
|
274812
|
+
default: defaultNetwork
|
|
274813
|
+
});
|
|
274814
|
+
return network;
|
|
274815
|
+
}
|
|
274816
|
+
|
|
274817
|
+
// src/commands/platform/blockchain-node/besu/create.ts
|
|
274818
|
+
function blockchainNodeBesuCreateCommand() {
|
|
274819
|
+
return getCreateCommand({
|
|
274820
|
+
name: "besu",
|
|
274821
|
+
type: "blockchain node",
|
|
274822
|
+
alias: "b",
|
|
274823
|
+
execute: (cmd2, baseAction) => {
|
|
274824
|
+
addClusterServiceArgs(cmd2).option("-a, --application-id <applicationId>", "The application ID to create the node in (defaults to application from env)").option("--blockchain-network-id <blockchainNetworkId>", "Blockchain network to add this node to").option("--node-identity <nodeIdentity>", "EC DSA P256 private key to use as the node identity").addOption(new Option("--node-type <nodeType>", "Type of the node").choices(["VALIDATOR", "NON_VALIDATOR"]).makeOptionMandatory()).action(async (name2, {
|
|
274825
|
+
applicationId,
|
|
274826
|
+
provider,
|
|
274827
|
+
region,
|
|
274828
|
+
size,
|
|
274829
|
+
type: type4,
|
|
274830
|
+
blockchainNetworkId,
|
|
274831
|
+
nodeType,
|
|
274832
|
+
nodeIdentity,
|
|
274833
|
+
acceptDefaults,
|
|
274834
|
+
...defaultArgs
|
|
274835
|
+
}) => {
|
|
274836
|
+
return baseAction(defaultArgs, async (settlemint, env2) => {
|
|
274837
|
+
const application = applicationId ?? env2.SETTLEMINT_APPLICATION;
|
|
274838
|
+
if (!application) {
|
|
274839
|
+
cancel2("No application found. Please specify an application or run `settlemint connect` to continue.");
|
|
274840
|
+
}
|
|
274841
|
+
let networkId = blockchainNetworkId ?? (acceptDefaults ? env2.SETTLEMINT_BLOCKCHAIN_NETWORK : undefined);
|
|
274842
|
+
if (!networkId) {
|
|
274843
|
+
const networks = await settlemint.blockchainNetwork.list(application);
|
|
274844
|
+
const network = await blockchainNetworkPrompt(env2, networks, acceptDefaults ?? false);
|
|
274845
|
+
if (!network) {
|
|
274846
|
+
cancel2("No network found. Please specify a network to continue.");
|
|
274847
|
+
}
|
|
274848
|
+
networkId = network?.id;
|
|
274849
|
+
}
|
|
274850
|
+
const result = await settlemint.blockchainNode.create({
|
|
274851
|
+
applicationId: application,
|
|
274852
|
+
name: name2,
|
|
274853
|
+
blockchainNetworkId: networkId,
|
|
274854
|
+
nodeType,
|
|
274855
|
+
keyMaterial: nodeIdentity,
|
|
274856
|
+
provider,
|
|
274857
|
+
region,
|
|
274858
|
+
size,
|
|
274859
|
+
type: type4
|
|
274860
|
+
});
|
|
274861
|
+
return {
|
|
274862
|
+
result,
|
|
274863
|
+
mapDefaultEnv: () => {
|
|
274864
|
+
return {
|
|
274865
|
+
SETTLEMINT_APPLICATION: application,
|
|
274866
|
+
SETTLEMINT_BLOCKCHAIN_NODE: result.id
|
|
274867
|
+
};
|
|
274868
|
+
}
|
|
274869
|
+
};
|
|
274870
|
+
});
|
|
274871
|
+
});
|
|
274872
|
+
},
|
|
274873
|
+
examples: [
|
|
274874
|
+
{
|
|
274875
|
+
description: "Create a Besu blockchain node and save as default",
|
|
274876
|
+
command: "platform create blockchain-node besu my-node --node-type VALIDATOR --accept-defaults -d"
|
|
274877
|
+
},
|
|
274878
|
+
{
|
|
274879
|
+
description: "Create a Besu blockchain node in a different network",
|
|
274880
|
+
command: "platform create blockchain-node besu my-node --blockchain-network-id 12345 --node-type NON_VALIDATOR --accept-defaults"
|
|
274881
|
+
},
|
|
274882
|
+
{
|
|
274883
|
+
description: "Create a Besu blockchain node in a different application",
|
|
274884
|
+
command: "platform create blockchain-node besu my-node --application-id 123456789 --node-type NON_VALIDATOR --accept-defaults"
|
|
274885
|
+
}
|
|
274886
|
+
]
|
|
274887
|
+
});
|
|
274888
|
+
}
|
|
274889
|
+
|
|
274890
|
+
// src/commands/platform/blockchain-node/create.ts
|
|
274891
|
+
function blockchainNodeCreateCommand() {
|
|
274892
|
+
return new Command2("blockchain-node").alias("bn").description("Create a blockchain node in the SettleMint platform").addCommand(blockchainNodeBesuCreateCommand());
|
|
274893
|
+
}
|
|
274894
|
+
|
|
274790
274895
|
// src/commands/platform/insights/blockscout/create.ts
|
|
274791
274896
|
function blockscoutInsightsCreateCommand() {
|
|
274792
274897
|
return getCreateCommand({
|
|
@@ -274902,16 +275007,14 @@ function graphMiddlewareCreateCommand() {
|
|
|
274902
275007
|
type: "middleware",
|
|
274903
275008
|
alias: "gr",
|
|
274904
275009
|
execute: (cmd2, baseAction) => {
|
|
274905
|
-
addClusterServiceArgs(cmd2).option("--application-id <applicationId>", "Application ID").option("--
|
|
275010
|
+
addClusterServiceArgs(cmd2).option("--application-id <applicationId>", "Application ID").option("--blockchain-node-id <blockchainNodeId>", "Blockchain Node ID").action(async (name2, { applicationId, blockchainNodeId, provider, region, size, type: type4, ...defaultArgs }) => {
|
|
274906
275011
|
return baseAction(defaultArgs, async (settlemint, env2) => {
|
|
274907
275012
|
const application = applicationId ?? env2.SETTLEMINT_APPLICATION;
|
|
274908
275013
|
const blockchainNode = blockchainNodeId ?? env2.SETTLEMINT_BLOCKCHAIN_NODE;
|
|
274909
|
-
const storage = storageId ?? env2.SETTLEMINT_IPFS;
|
|
274910
275014
|
const result = await settlemint.middleware.create({
|
|
274911
275015
|
name: name2,
|
|
274912
275016
|
applicationId: application,
|
|
274913
275017
|
interface: "HA_GRAPH",
|
|
274914
|
-
storageId: storage,
|
|
274915
275018
|
blockchainNodeId: blockchainNode,
|
|
274916
275019
|
provider,
|
|
274917
275020
|
region,
|
|
@@ -275227,7 +275330,7 @@ function storageCreateCommand() {
|
|
|
275227
275330
|
|
|
275228
275331
|
// src/commands/platform/create.ts
|
|
275229
275332
|
function createCommand3() {
|
|
275230
|
-
return new Command2("create").alias("c").description("Create a resource in the SettleMint platform").addCommand(workspaceCreateCommand()).addCommand(applicationCreateCommand()).addCommand(blockchainNetworkCreateCommand()).addCommand(privateKeyCreateCommand()).addCommand(middlewareCreateCommand()).addCommand(storageCreateCommand()).addCommand(integrationToolCreateCommand()).addCommand(insightsCreateCommand()).addCommand(applicationAccessTokenCreateCommand());
|
|
275333
|
+
return new Command2("create").alias("c").description("Create a resource in the SettleMint platform").addCommand(workspaceCreateCommand()).addCommand(applicationCreateCommand()).addCommand(blockchainNetworkCreateCommand()).addCommand(blockchainNodeCreateCommand()).addCommand(privateKeyCreateCommand()).addCommand(middlewareCreateCommand()).addCommand(storageCreateCommand()).addCommand(integrationToolCreateCommand()).addCommand(insightsCreateCommand()).addCommand(applicationAccessTokenCreateCommand());
|
|
275231
275334
|
}
|
|
275232
275335
|
|
|
275233
275336
|
// src/commands/platform/prompts/delete-confirmation.prompt.ts
|
|
@@ -276508,4 +276611,4 @@ sdkcli.parseAsync(process.argv).catch((reason) => {
|
|
|
276508
276611
|
cancel2(reason);
|
|
276509
276612
|
});
|
|
276510
276613
|
|
|
276511
|
-
//# debugId=
|
|
276614
|
+
//# debugId=427E4F0AD5970B1564756E2164756E21
|